diff --git a/README.md b/README.md
index 08afd44cc4a8bf64a42390c09b46b76973a38cb4..fdfec0f687c4dc44082f5355a5cebac44ed94aae 100644
--- a/README.md
+++ b/README.md
@@ -1,93 +1,50 @@
 # notebooks-nvidia-device-plugin
 
+## What is this repo?
+This repo contains custom Nvidia Device Plugin that allows us to deploy Jupyter notebooks from our Kubernetes Jupyterhub onto gpus with active migs (migs simply divide gpus into smaller equal units, allowing multiple users to work concurently on a single gpu with devided resources. The original Nvidia Device Plugin for some unknown reason doesnt allow the master node to see and work with migs on worker nodes.
 
-
-## Getting started
-
-To make it easy for you to get started with GitLab, here's a list of recommended next steps.
-
-Already a pro? Just edit this README.md and make it your own. Want to make it easy? [Use the template at the bottom](#editing-this-readme)!
-
-## Add your files
-
-- [ ] [Create](https://docs.gitlab.com/ee/user/project/repository/web_editor.html#create-a-file) or [upload](https://docs.gitlab.com/ee/user/project/repository/web_editor.html#upload-a-file) files
-- [ ] [Add files using the command line](https://docs.gitlab.com/ee/gitlab-basics/add-file.html#add-a-file-using-the-command-line) or push an existing Git repository with the following command:
+## How to make the migs work?
+Activate migs on target GPU, for example using these commands (repeat to create multiple migs)
 
 ```
-cd existing_repo
-git remote add origin https://gitlab.cesnet.cz/702/projekty/eosc-notebooks/notebooks-nvidia-device-plugin.git
-git branch -M main
-git push -uf origin main
+nvidia-smi -mig 1
+nvidia-smi mig -cci 1g.12gb
+nvidia-smi mig -cgi 1g.12gb
 ```
 
-## Integrate with your tools
-
-- [ ] [Set up project integrations](https://gitlab.cesnet.cz/702/projekty/eosc-notebooks/notebooks-nvidia-device-plugin/-/settings/integrations)
-
-## Collaborate with your team
-
-- [ ] [Invite team members and collaborators](https://docs.gitlab.com/ee/user/project/members/)
-- [ ] [Create a new merge request](https://docs.gitlab.com/ee/user/project/merge_requests/creating_merge_requests.html)
-- [ ] [Automatically close issues from merge requests](https://docs.gitlab.com/ee/user/project/issues/managing_issues.html#closing-issues-automatically)
-- [ ] [Enable merge request approvals](https://docs.gitlab.com/ee/user/project/merge_requests/approvals/)
-- [ ] [Set auto-merge](https://docs.gitlab.com/ee/user/project/merge_requests/merge_when_pipeline_succeeds.html)
-
-## Test and Deploy
-
-Use the built-in continuous integration in GitLab.
-
-- [ ] [Get started with GitLab CI/CD](https://docs.gitlab.com/ee/ci/quick_start/index.html)
-- [ ] [Analyze your code for known vulnerabilities with Static Application Security Testing (SAST)](https://docs.gitlab.com/ee/user/application_security/sast/)
-- [ ] [Deploy to Kubernetes, Amazon EC2, or Amazon ECS using Auto Deploy](https://docs.gitlab.com/ee/topics/autodevops/requirements.html)
-- [ ] [Use pull-based deployments for improved Kubernetes management](https://docs.gitlab.com/ee/user/clusters/agent/)
-- [ ] [Set up protected environments](https://docs.gitlab.com/ee/ci/environments/protected_environments.html)
-
-***
-
-# Editing this README
-
-When you're ready to make this README your own, just edit this file and use the handy template below (or feel free to structure it however you want - this is just a starting point!). Thanks to [makeareadme.com](https://www.makeareadme.com/) for this template.
-
-## Suggestions for a good README
-
-Every project is different, so consider which of these sections apply to yours. The sections used in the template are suggestions for most open source projects. Also keep in mind that while a README can be too long and detailed, too long is better than too short. If you think your README is too long, consider utilizing another form of documentation rather than cutting out information.
-
-## Name
-Choose a self-explaining name for your project.
-
-## Description
-Let people know what your project can do specifically. Provide context and add a link to any reference visitors might be unfamiliar with. A list of Features or a Background subsection can also be added here. If there are alternatives to your project, this is a good place to list differentiating factors.
-
-## Badges
-On some READMEs, you may see small images that convey metadata, such as whether or not all the tests are passing for the project. You can use Shields to add some to your README. Many services also have instructions for adding a badge.
-
-## Visuals
-Depending on what you are making, it can be a good idea to include screenshots or even a video (you'll frequently see GIFs rather than actual videos). Tools like ttygif can help, but check out Asciinema for a more sophisticated method.
+Other useful arguments to show and delete migs are
+```
+-lci -lgi -dci -dgi
+```
 
-## Installation
-Within a particular ecosystem, there may be a common way of installing things, such as using Yarn, NuGet, or Homebrew. However, consider the possibility that whoever is reading your README is a novice and would like more guidance. Listing specific steps helps remove ambiguity and gets people to using your project as quickly as possible. If it only runs in a specific context like a particular programming language version or operating system or has dependencies that have to be installed manually, also add a Requirements subsection.
+When migs are correctly setup, install custom Nvidia Device Plugin onto the master node (where jupyterhub is installed)
 
-## Usage
-Use examples liberally, and show the expected output if you can. It's helpful to have inline the smallest example of usage that you can demonstrate, while providing links to more sophisticated examples if they are too long to reasonably include in the README.
+```
+helm install nvidia-device-plugin-custom ./nvidia-device-plugin-custom/ -n kube-system
+```
 
-## Support
-Tell people where they can go to for help. It can be any combination of an issue tracker, a chat room, an email address, etc.
+Check that the master node correctly sees the migs
+```
+kubectl describe node k8s-staging1-gpu-0
+```
+where this line should contain the number of available migs (should be 1 or more)
+```
+nvidia.com/mig-1g.11gb:  7
+```
 
-## Roadmap
-If you have ideas for releases in the future, it is a good idea to list them in the README.
+Other useful commands to work with the plugin
+```
+helm uninstall nvidia-device-plugin-custom -n kube-system
+kubectl delete pod -n kube-system nvidia-device-plugin-egi-5xwsm
+kubectl logs nvidia-device-plugin-egi-87bkb -n kube-system
+```
 
-## Contributing
-State if you are open to contributions and what your requirements are for accepting them.
+## How to test and benchmark the migs?
 
-For people who want to make changes to your project, it's helpful to have some documentation on how to get started. Perhaps there is a script that they should run or some environment variables that they need to set. Make these steps explicit. These instructions could also be useful to your future self.
+Folder `test-mig-master` shows how to describe migs in kubernetes yaml file and how to display the migs using nvidia-smi inside kubernetes container.
 
-You can also document commands to lint the code or run tests. These steps help to ensure high code quality and reduce the likelihood that the changes inadvertently break something. Having instructions for running tests is especially helpful if it requires external setup, such as starting a Selenium server for testing in a browser.
+Folder `benchmark` constain python code with timed matrix multiplication algorithm to test the performance of the migs and whole gpus. Adjust the N variable representing the size of matrices. We tested with N=16384, one whole nvidia H100 gpu without migs was able to complete the benchmark in exactly 10 seconds, and after diving the gpu into 7 equal migs (the highest amount available, no smaller migs are possible on H100), each mig was able to run the same benchmark in 75s (+-1s) regardless of the total number of migs running the benchmark. That shows that there is very little overhead with using migs and performance of all migs is almost equal the performance of the same mig-less gpu, and also that  the performance for each user wont be affected by other users using other migs on the same gpu.
 
-## Authors and acknowledgment
-Show your appreciation to those who have contributed to the project.
+Folder `test-mig-jupyterlab` shows how to test the migs inside a docker container within the environment of a single jupyterlab notebook.
 
-## License
-For open source projects, say how it is licensed.
 
-## Project status
-If you have run out of energy or time for your project, put a note at the top of the README saying that development has slowed down or stopped completely. Someone may choose to fork your project or volunteer to step in as a maintainer or owner, allowing your project to keep going. You can also make an explicit request for maintainers.
diff --git a/benchmark/build_run.sh b/benchmark/build_run.sh
new file mode 100755
index 0000000000000000000000000000000000000000..42e463a02bb7f60189a5190a0c7a6eb1b76269f2
--- /dev/null
+++ b/benchmark/build_run.sh
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+NAME=test-mig
+
+docker image build --network host -t $NAME .
+docker run --rm -it --network host $NAME
diff --git a/benchmark/dockerfile b/benchmark/dockerfile
new file mode 100644
index 0000000000000000000000000000000000000000..bd377bab2f4d7c03e093843781c41cb066810941
--- /dev/null
+++ b/benchmark/dockerfile
@@ -0,0 +1,18 @@
+FROM nvidia/cuda:12.6.1-devel-ubuntu22.04
+
+# Install Python and required libraries
+RUN apt-get update && apt-get install -y python3 python3-pip && \
+    pip3 install numba numpy && \
+    apt-get clean
+
+# Copy the Python script into the container
+COPY gpu_test_time.py /app/gpu_test.py
+
+# Set the working directory
+WORKDIR /app
+
+# the uuid comes from $ nvidia-smi --query-gpu=index,uuid --format=csv
+RUN export CUDA_VISIBLE_DEVICES=GPU-bdabf532-16b6-546f-0103-1461eb65e40b
+
+# Command to run the script
+CMD ["python3", "gpu_test.py"]
diff --git a/benchmark/gpu_test_time.py b/benchmark/gpu_test_time.py
new file mode 100644
index 0000000000000000000000000000000000000000..e0437c5f3a38de97bd3dac82070ee5c90bdd9ad7
--- /dev/null
+++ b/benchmark/gpu_test_time.py
@@ -0,0 +1,56 @@
+from numba import cuda
+import numpy as np
+import os
+import time
+
+# Check the GPU assigned by CUDA
+device = cuda.get_current_device()
+print(f"Running on device: {device.name}")
+
+# Define kernel
+@cuda.jit
+def matrix_mult(A, B, C):
+    row, col = cuda.grid(2)
+    if row < C.shape[0] and col < C.shape[1]:
+        tmp = 0
+        for k in range(A.shape[1]):
+            tmp += A[row, k] * B[k, col]
+        C[row, col] = tmp
+
+# Initialize matrices
+N = 4096  # Small matrix size
+A = np.random.rand(N, N).astype(np.float32)
+B = np.random.rand(N, N).astype(np.float32)
+C = np.zeros((N, N), dtype=np.float32)
+
+# Transfer data to GPU
+A_device = cuda.to_device(A)
+B_device = cuda.to_device(B)
+C_device = cuda.device_array((N, N), dtype=np.float32)
+
+# Define thread/block layout
+threads_per_block = (16, 16)
+blocks_per_grid_x = int(np.ceil(C.shape[0] / threads_per_block[0]))
+blocks_per_grid_y = int(np.ceil(C.shape[1] / threads_per_block[1]))
+blocks_per_grid = (blocks_per_grid_x, blocks_per_grid_y)
+
+# Measure start time
+start_time = time.time()
+
+# Launch the kernel
+matrix_mult[blocks_per_grid, threads_per_block](A_device, B_device, C_device)
+
+# Copy result back to host
+C = C_device.copy_to_host()
+print("Matrix multiplication result:")
+print(C)
+
+# Wait for the GPU to finish
+cuda.synchronize()
+
+# Measure end time
+end_time = time.time()
+
+# Print elapsed time
+print(f"Time taken for GPU computation: {end_time - start_time:.6f} seconds")
+
diff --git a/nvidia-device-plugin-custom/.helmignore b/nvidia-device-plugin-custom/.helmignore
new file mode 100644
index 0000000000000000000000000000000000000000..0e8a0eb36f4ca2c939201c0d54b5d82a1ea34778
--- /dev/null
+++ b/nvidia-device-plugin-custom/.helmignore
@@ -0,0 +1,23 @@
+# Patterns to ignore when building packages.
+# This supports shell glob matching, relative path matching, and
+# negation (prefixed with !). Only one pattern per line.
+.DS_Store
+# Common VCS dirs
+.git/
+.gitignore
+.bzr/
+.bzrignore
+.hg/
+.hgignore
+.svn/
+# Common backup files
+*.swp
+*.bak
+*.tmp
+*.orig
+*~
+# Various IDEs
+.project
+.idea/
+*.tmproj
+.vscode/
diff --git a/nvidia-device-plugin-custom/Chart.yaml b/nvidia-device-plugin-custom/Chart.yaml
new file mode 100644
index 0000000000000000000000000000000000000000..a1a580e7927d7f40a40238de354c31c7e8032d39
--- /dev/null
+++ b/nvidia-device-plugin-custom/Chart.yaml
@@ -0,0 +1,24 @@
+apiVersion: v2
+name: nvidia-device-plugin-egi
+description: NVIDIA Device Plugin for Kubernetes
+
+# A chart can be either an 'application' or a 'library' chart.
+#
+# Application charts are a collection of templates that can be packaged into versioned archives
+# to be deployed.
+#
+# Library charts provide useful utilities or functions for the chart developer. They're included as
+# a dependency of application charts to inject those utilities and functions into the rendering
+# pipeline. Library charts do not define any templates and therefore cannot be deployed.
+type: application
+
+# This is the chart version. This version number should be incremented each time you make changes
+# to the chart and its templates, including the app version.
+# Versions are expected to follow Semantic Versioning (https://semver.org/)
+version: 0.12.0
+
+# This is the version number of the application being deployed. This version number should be
+# incremented each time you make changes to the application. Versions are not expected to
+# follow Semantic Versioning. They should reflect the version the application is using.
+# It is recommended to use it with quotes.
+appVersion: "0.12.0"
diff --git a/nvidia-device-plugin-custom/templates/NOTES.txt b/nvidia-device-plugin-custom/templates/NOTES.txt
new file mode 100644
index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391
diff --git a/nvidia-device-plugin-custom/templates/_helpers.tpl b/nvidia-device-plugin-custom/templates/_helpers.tpl
new file mode 100644
index 0000000000000000000000000000000000000000..fb17a0be2d2b75d29f26113a2f825c053c07fbc4
--- /dev/null
+++ b/nvidia-device-plugin-custom/templates/_helpers.tpl
@@ -0,0 +1,62 @@
+{{/*
+Expand the name of the chart.
+*/}}
+{{- define "nvidia-device-plugin-egi.name" -}}
+{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
+{{- end }}
+
+{{/*
+Create a default fully qualified app name.
+We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
+If release name contains chart name it will be used as a full name.
+*/}}
+{{- define "nvidia-device-plugin-egi.fullname" -}}
+{{- if .Values.fullnameOverride }}
+{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
+{{- else }}
+{{- $name := default .Chart.Name .Values.nameOverride }}
+{{- if contains $name .Release.Name }}
+{{- .Release.Name | trunc 63 | trimSuffix "-" }}
+{{- else }}
+{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
+{{- end }}
+{{- end }}
+{{- end }}
+
+{{/*
+Create chart name and version as used by the chart label.
+*/}}
+{{- define "nvidia-device-plugin-egi.chart" -}}
+{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
+{{- end }}
+
+{{/*
+Common labels
+*/}}
+{{- define "nvidia-device-plugin-egi.labels" -}}
+helm.sh/chart: {{ include "nvidia-device-plugin-egi.chart" . }}
+{{ include "nvidia-device-plugin-egi.selectorLabels" . }}
+{{- if .Chart.AppVersion }}
+app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
+{{- end }}
+app.kubernetes.io/managed-by: {{ .Release.Service }}
+{{- end }}
+
+{{/*
+Selector labels
+*/}}
+{{- define "nvidia-device-plugin-egi.selectorLabels" -}}
+app.kubernetes.io/name: {{ include "nvidia-device-plugin-egi.name" . }}
+app.kubernetes.io/instance: {{ .Release.Name }}
+{{- end }}
+
+{{/*
+Create the name of the service account to use
+*/}}
+{{- define "nvidia-device-plugin-egi.serviceAccountName" -}}
+{{- if .Values.serviceAccount.create }}
+{{- default (include "nvidia-device-plugin-egi.fullname" .) .Values.serviceAccount.name }}
+{{- else }}
+{{- default "default" .Values.serviceAccount.name }}
+{{- end }}
+{{- end }}
diff --git a/nvidia-device-plugin-custom/templates/deployment.yaml b/nvidia-device-plugin-custom/templates/deployment.yaml
new file mode 100644
index 0000000000000000000000000000000000000000..3894730565089c65f17ca66a6c31e89eaa43b40f
--- /dev/null
+++ b/nvidia-device-plugin-custom/templates/deployment.yaml
@@ -0,0 +1,68 @@
+apiVersion: apps/v1
+kind: Deployment
+metadata:
+  name: {{ include "nvidia-device-plugin-egi.fullname" . }}
+  labels:
+    {{- include "nvidia-device-plugin-egi.labels" . | nindent 4 }}
+spec:
+  {{- if not .Values.autoscaling.enabled }}
+  replicas: {{ .Values.replicaCount }}
+  {{- end }}
+  selector:
+    matchLabels:
+      {{- include "nvidia-device-plugin-egi.selectorLabels" . | nindent 6 }}
+  template:
+    metadata:
+      {{- with .Values.podAnnotations }}
+      annotations:
+        {{- toYaml . | nindent 8 }}
+      {{- end }}
+      labels:
+        {{- include "nvidia-device-plugin-egi.labels" . | nindent 8 }}
+        {{- with .Values.podLabels }}
+        {{- toYaml . | nindent 8 }}
+        {{- end }}
+    spec:
+      {{- with .Values.imagePullSecrets }}
+      imagePullSecrets:
+        {{- toYaml . | nindent 8 }}
+      {{- end }}
+      serviceAccountName: {{ include "nvidia-device-plugin-egi.serviceAccountName" . }}
+      securityContext:
+        {{- toYaml .Values.podSecurityContext | nindent 8 }}
+      containers:
+        - name: {{ .Chart.Name }}
+          securityContext:
+            {{- toYaml .Values.securityContext | nindent 12 }}
+          image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
+          imagePullPolicy: {{ .Values.image.pullPolicy }}
+          ports:
+            - name: http
+              containerPort: {{ .Values.service.port }}
+              protocol: TCP
+          livenessProbe:
+            {{- toYaml .Values.livenessProbe | nindent 12 }}
+          readinessProbe:
+            {{- toYaml .Values.readinessProbe | nindent 12 }}
+          resources:
+            {{- toYaml .Values.resources | nindent 12 }}
+          {{- with .Values.volumeMounts }}
+          volumeMounts:
+            {{- toYaml . | nindent 12 }}
+          {{- end }}
+      {{- with .Values.volumes }}
+      volumes:
+        {{- toYaml . | nindent 8 }}
+      {{- end }}
+      {{- with .Values.nodeSelector }}
+      nodeSelector:
+        {{- toYaml . | nindent 8 }}
+      {{- end }}
+      {{- with .Values.affinity }}
+      affinity:
+        {{- toYaml . | nindent 8 }}
+      {{- end }}
+      {{- with .Values.tolerations }}
+      tolerations:
+        {{- toYaml . | nindent 8 }}
+      {{- end }}
diff --git a/nvidia-device-plugin-custom/templates/egi.yml b/nvidia-device-plugin-custom/templates/egi.yml
new file mode 100644
index 0000000000000000000000000000000000000000..2fe67fd9a7c5075ec8b5ef67833147415dba2a35
--- /dev/null
+++ b/nvidia-device-plugin-custom/templates/egi.yml
@@ -0,0 +1,80 @@
+---
+# Source: nvidia-device-plugin/templates/daemonset.yml
+# Copyright (c) 2019, NVIDIA CORPORATION.  All rights reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+apiVersion: apps/v1
+kind: DaemonSet
+metadata:
+  name: nvidia-device-plugin-egi
+  namespace: kube-system
+  labels:
+    helm.sh/chart: nvidia-device-plugin-egi
+    app.kubernetes.io/name: nvidia-device-plugin-egi
+    app.kubernetes.io/instance: nvidia-device-plugin-egi
+    app.kubernetes.io/version: "0.12.0"
+    app.kubernetes.io/managed-by: Helm
+spec:
+  selector:
+    matchLabels:
+      app.kubernetes.io/name: nvidia-device-plugin-egi
+      app.kubernetes.io/instance: nvidia-device-plugin-egi
+  updateStrategy:
+    type: RollingUpdate
+  template:
+    metadata:
+      # This annotation is deprecated. Kept here for backward compatibility
+      # See https://kubernetes.io/docs/tasks/administer-cluster/guaranteed-scheduling-critical-addon-pods/
+    # annotations:
+    #   scheduler.alpha.kubernetes.io/critical-pod: ""
+      labels:
+        app.kubernetes.io/name: nvidia-device-plugin-egi
+        app.kubernetes.io/instance: nvidia-device-plugin-egi
+    spec:
+      # Mark this pod as a critical add-on; when enabled, the critical add-on
+      # scheduler reserves resources for critical add-on pods so that they can
+      # be rescheduled after a failure.
+      # See https://kubernetes.io/docs/tasks/administer-cluster/guaranteed-scheduling-critical-addon-pods/
+      priorityClassName: "system-node-critical"
+      securityContext:
+        {}
+      containers:
+      - image: nvcr.io/nvidia/k8s-device-plugin:v0.12.0
+        imagePullPolicy: IfNotPresent
+        name: nvidia-device-plugin-egi-ctr
+        args:
+        - "--mig-strategy=mixed"
+        - "--pass-device-specs=false"
+        - "--fail-on-init-error=true"
+        - "--device-list-strategy=envvar"
+        - "--device-id-strategy=uuid"
+        - "--nvidia-driver-root=/"
+        securityContext:
+          allowPrivilegeEscalation: false
+          capabilities:
+            drop: ["ALL"]
+        volumeMounts:
+          - name: device-plugin
+            mountPath: /var/lib/kubelet/device-plugins
+      volumes:
+        - name: device-plugin
+          hostPath:
+            path: /var/lib/kubelet/device-plugins
+      tolerations:
+        - key: CriticalAddonsOnly
+          operator: Exists
+        - effect: NoSchedule
+          key: nvidia.com/gpu
+          operator: Exists
+      nodeSelector:
+        gpu: "true"
diff --git a/nvidia-device-plugin-custom/templates/hpa.yaml b/nvidia-device-plugin-custom/templates/hpa.yaml
new file mode 100644
index 0000000000000000000000000000000000000000..07d8132f8e71e1c96a8e047346549180e0161f59
--- /dev/null
+++ b/nvidia-device-plugin-custom/templates/hpa.yaml
@@ -0,0 +1,32 @@
+{{- if .Values.autoscaling.enabled }}
+apiVersion: autoscaling/v2
+kind: HorizontalPodAutoscaler
+metadata:
+  name: {{ include "nvidia-device-plugin-egi.fullname" . }}
+  labels:
+    {{- include "nvidia-device-plugin-egi.labels" . | nindent 4 }}
+spec:
+  scaleTargetRef:
+    apiVersion: apps/v1
+    kind: Deployment
+    name: {{ include "nvidia-device-plugin-egi.fullname" . }}
+  minReplicas: {{ .Values.autoscaling.minReplicas }}
+  maxReplicas: {{ .Values.autoscaling.maxReplicas }}
+  metrics:
+    {{- if .Values.autoscaling.targetCPUUtilizationPercentage }}
+    - type: Resource
+      resource:
+        name: cpu
+        target:
+          type: Utilization
+          averageUtilization: {{ .Values.autoscaling.targetCPUUtilizationPercentage }}
+    {{- end }}
+    {{- if .Values.autoscaling.targetMemoryUtilizationPercentage }}
+    - type: Resource
+      resource:
+        name: memory
+        target:
+          type: Utilization
+          averageUtilization: {{ .Values.autoscaling.targetMemoryUtilizationPercentage }}
+    {{- end }}
+{{- end }}
diff --git a/nvidia-device-plugin-custom/templates/ingress.yaml b/nvidia-device-plugin-custom/templates/ingress.yaml
new file mode 100644
index 0000000000000000000000000000000000000000..920304d5303d62cf71453bdadaca6050cdcf556c
--- /dev/null
+++ b/nvidia-device-plugin-custom/templates/ingress.yaml
@@ -0,0 +1,43 @@
+{{- if .Values.ingress.enabled -}}
+apiVersion: networking.k8s.io/v1
+kind: Ingress
+metadata:
+  name: {{ include "nvidia-device-plugin-egi.fullname" . }}
+  labels:
+    {{- include "nvidia-device-plugin-egi.labels" . | nindent 4 }}
+  {{- with .Values.ingress.annotations }}
+  annotations:
+    {{- toYaml . | nindent 4 }}
+  {{- end }}
+spec:
+  {{- with .Values.ingress.className }}
+  ingressClassName: {{ . }}
+  {{- end }}
+  {{- if .Values.ingress.tls }}
+  tls:
+    {{- range .Values.ingress.tls }}
+    - hosts:
+        {{- range .hosts }}
+        - {{ . | quote }}
+        {{- end }}
+      secretName: {{ .secretName }}
+    {{- end }}
+  {{- end }}
+  rules:
+    {{- range .Values.ingress.hosts }}
+    - host: {{ .host | quote }}
+      http:
+        paths:
+          {{- range .paths }}
+          - path: {{ .path }}
+            {{- with .pathType }}
+            pathType: {{ . }}
+            {{- end }}
+            backend:
+              service:
+                name: {{ include "nvidia-device-plugin-egi.fullname" $ }}
+                port:
+                  number: {{ $.Values.service.port }}
+          {{- end }}
+    {{- end }}
+{{- end }}
diff --git a/nvidia-device-plugin-custom/templates/service.yaml b/nvidia-device-plugin-custom/templates/service.yaml
new file mode 100644
index 0000000000000000000000000000000000000000..3015916b0983c65827c9fbc6d74748974cc67729
--- /dev/null
+++ b/nvidia-device-plugin-custom/templates/service.yaml
@@ -0,0 +1,15 @@
+apiVersion: v1
+kind: Service
+metadata:
+  name: {{ include "nvidia-device-plugin-egi.fullname" . }}
+  labels:
+    {{- include "nvidia-device-plugin-egi.labels" . | nindent 4 }}
+spec:
+  type: {{ .Values.service.type }}
+  ports:
+    - port: {{ .Values.service.port }}
+      targetPort: http
+      protocol: TCP
+      name: http
+  selector:
+    {{- include "nvidia-device-plugin-egi.selectorLabels" . | nindent 4 }}
diff --git a/nvidia-device-plugin-custom/templates/serviceaccount.yaml b/nvidia-device-plugin-custom/templates/serviceaccount.yaml
new file mode 100644
index 0000000000000000000000000000000000000000..df3a4159c845b17a7948e91c99a74c9d549b240f
--- /dev/null
+++ b/nvidia-device-plugin-custom/templates/serviceaccount.yaml
@@ -0,0 +1,13 @@
+{{- if .Values.serviceAccount.create -}}
+apiVersion: v1
+kind: ServiceAccount
+metadata:
+  name: {{ include "nvidia-device-plugin-egi.serviceAccountName" . }}
+  labels:
+    {{- include "nvidia-device-plugin-egi.labels" . | nindent 4 }}
+  {{- with .Values.serviceAccount.annotations }}
+  annotations:
+    {{- toYaml . | nindent 4 }}
+  {{- end }}
+automountServiceAccountToken: {{ .Values.serviceAccount.automount }}
+{{- end }}
diff --git a/nvidia-device-plugin-custom/templates/tests/test-connection.yaml b/nvidia-device-plugin-custom/templates/tests/test-connection.yaml
new file mode 100644
index 0000000000000000000000000000000000000000..59ecb9b02fffd5161c6ddc9355c65f739d03cb5e
--- /dev/null
+++ b/nvidia-device-plugin-custom/templates/tests/test-connection.yaml
@@ -0,0 +1,15 @@
+apiVersion: v1
+kind: Pod
+metadata:
+  name: "{{ include "nvidia-device-plugin-egi.fullname" . }}-test-connection"
+  labels:
+    {{- include "nvidia-device-plugin-egi.labels" . | nindent 4 }}
+  annotations:
+    "helm.sh/hook": test
+spec:
+  containers:
+    - name: wget
+      image: busybox
+      command: ['wget']
+      args: ['{{ include "nvidia-device-plugin-egi.fullname" . }}:{{ .Values.service.port }}']
+  restartPolicy: Never
diff --git a/nvidia-device-plugin-custom/values.yaml b/nvidia-device-plugin-custom/values.yaml
new file mode 100644
index 0000000000000000000000000000000000000000..0355b159e8eb9ece779e8255dcdb6825da668009
--- /dev/null
+++ b/nvidia-device-plugin-custom/values.yaml
@@ -0,0 +1,123 @@
+# Default values for nvidia-device-plugin-egi.
+# This is a YAML-formatted file.
+# Declare variables to be passed into your templates.
+
+# This will set the replicaset count more information can be found here: https://kubernetes.io/docs/concepts/workloads/controllers/replicaset/
+replicaCount: 0
+
+# This sets the container image more information can be found here: https://kubernetes.io/docs/concepts/containers/images/
+image:
+  repository: nginx
+  # This sets the pull policy for images.
+  pullPolicy: IfNotPresent
+  # Overrides the image tag whose default is the chart appVersion.
+  tag: ""
+
+# This is for the secretes for pulling an image from a private repository more information can be found here: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/
+imagePullSecrets: []
+# This is to override the chart name.
+nameOverride: ""
+fullnameOverride: ""
+
+#This section builds out the service account more information can be found here: https://kubernetes.io/docs/concepts/security/service-accounts/
+serviceAccount:
+  # Specifies whether a service account should be created
+  create: true
+  # Automatically mount a ServiceAccount's API credentials?
+  automount: true
+  # Annotations to add to the service account
+  annotations: {}
+  # The name of the service account to use.
+  # If not set and create is true, a name is generated using the fullname template
+  name: ""
+
+# This is for setting Kubernetes Annotations to a Pod.
+# For more information checkout: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ 
+podAnnotations: {}
+# This is for setting Kubernetes Labels to a Pod.
+# For more information checkout: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/
+podLabels: {}
+
+podSecurityContext: {}
+  # fsGroup: 2000
+
+securityContext: {}
+  # capabilities:
+  #   drop:
+  #   - ALL
+  # readOnlyRootFilesystem: true
+  # runAsNonRoot: true
+  # runAsUser: 1000
+
+# This is for setting up a service more information can be found here: https://kubernetes.io/docs/concepts/services-networking/service/
+service:
+  # This sets the service type more information can be found here: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types
+  type: ClusterIP
+  # This sets the ports more information can be found here: https://kubernetes.io/docs/concepts/services-networking/service/#field-spec-ports
+  port: 80
+
+# This block is for setting up the ingress for more information can be found here: https://kubernetes.io/docs/concepts/services-networking/ingress/
+ingress:
+  enabled: false
+  className: ""
+  annotations: {}
+    # kubernetes.io/ingress.class: nginx
+    # kubernetes.io/tls-acme: "true"
+  hosts:
+    - host: chart-example.local
+      paths:
+        - path: /
+          pathType: ImplementationSpecific
+  tls: []
+  #  - secretName: chart-example-tls
+  #    hosts:
+  #      - chart-example.local
+
+resources: {}
+  # We usually recommend not to specify default resources and to leave this as a conscious
+  # choice for the user. This also increases chances charts run on environments with little
+  # resources, such as Minikube. If you do want to specify resources, uncomment the following
+  # lines, adjust them as necessary, and remove the curly braces after 'resources:'.
+  # limits:
+  #   cpu: 100m
+  #   memory: 128Mi
+  # requests:
+  #   cpu: 100m
+  #   memory: 128Mi
+
+# This is to setup the liveness and readiness probes more information can be found here: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/
+livenessProbe:
+  httpGet:
+    path: /
+    port: http
+readinessProbe:
+  httpGet:
+    path: /
+    port: http
+
+#This section is for setting up autoscaling more information can be found here: https://kubernetes.io/docs/concepts/workloads/autoscaling/
+autoscaling:
+  enabled: false
+  minReplicas: 0
+  maxReplicas: 100
+  targetCPUUtilizationPercentage: 80
+  # targetMemoryUtilizationPercentage: 80
+
+# Additional volumes on the output Deployment definition.
+volumes: []
+# - name: foo
+#   secret:
+#     secretName: mysecret
+#     optional: false
+
+# Additional volumeMounts on the output Deployment definition.
+volumeMounts: []
+# - name: foo
+#   mountPath: "/etc/foo"
+#   readOnly: true
+
+nodeSelector: {}
+
+tolerations: []
+
+affinity: {}
diff --git a/test-mig-jupyterlab/build_run.sh b/test-mig-jupyterlab/build_run.sh
new file mode 100755
index 0000000000000000000000000000000000000000..527ddc43b804df304a72f4d01b1274f4f37719fe
--- /dev/null
+++ b/test-mig-jupyterlab/build_run.sh
@@ -0,0 +1,17 @@
+#!/bin/sh
+
+# Check if MIG ID is provided
+if [ -z "$1" ]; then
+  echo "Usage: $0 <MIG_UUID>"
+  exit 1
+fi
+
+MIG_UUID="$1"
+
+NAME=jupyterlab-test-mig
+
+docker image build --network host -t $NAME .
+docker run --rm -it --network host \
+  --gpus "\"device=$MIG_UUID\"" \
+  -e NVIDIA_VISIBLE_DEVICES="$MIG_UUID" \
+  $NAME
diff --git a/test-mig-jupyterlab/dockerfile b/test-mig-jupyterlab/dockerfile
new file mode 100644
index 0000000000000000000000000000000000000000..958bb664e2053470bf03536bab32dd1d31faba2a
--- /dev/null
+++ b/test-mig-jupyterlab/dockerfile
@@ -0,0 +1,26 @@
+FROM nvidia/cuda:12.6.1-devel-ubuntu22.04
+
+# Install Python and dependencies
+RUN apt-get update && apt-get install -y \
+    python3-pip python3-dev curl && \
+    pip3 install --no-cache-dir \
+    jupyterlab numba numpy && \
+    apt-get clean
+
+# Set environment variables for CUDA
+ENV PATH=/usr/local/cuda/bin:$PATH
+ENV LD_LIBRARY_PATH=/usr/local/cuda/lib64:$LD_LIBRARY_PATH
+
+EXPOSE 80
+
+# Copy the Python script into the container
+COPY gpu_test_time.py /app/gpu_test.py
+
+# Set the working directory
+WORKDIR /app
+
+# the uuid comes from $ nvidia-smi --query-gpu=index,uuid --format=csv
+#RUN export CUDA_VISIBLE_DEVICES=GPU-bdabf532-16b6-546f-0103-1461eb65e40b
+
+# Set default command to start JupyterLab
+CMD ["jupyter-lab", "--ip=0.0.0.0", "--allow-root", "--port=80"]
diff --git a/test-mig-jupyterlab/gpu_test_time.py b/test-mig-jupyterlab/gpu_test_time.py
new file mode 100644
index 0000000000000000000000000000000000000000..e0437c5f3a38de97bd3dac82070ee5c90bdd9ad7
--- /dev/null
+++ b/test-mig-jupyterlab/gpu_test_time.py
@@ -0,0 +1,56 @@
+from numba import cuda
+import numpy as np
+import os
+import time
+
+# Check the GPU assigned by CUDA
+device = cuda.get_current_device()
+print(f"Running on device: {device.name}")
+
+# Define kernel
+@cuda.jit
+def matrix_mult(A, B, C):
+    row, col = cuda.grid(2)
+    if row < C.shape[0] and col < C.shape[1]:
+        tmp = 0
+        for k in range(A.shape[1]):
+            tmp += A[row, k] * B[k, col]
+        C[row, col] = tmp
+
+# Initialize matrices
+N = 4096  # Small matrix size
+A = np.random.rand(N, N).astype(np.float32)
+B = np.random.rand(N, N).astype(np.float32)
+C = np.zeros((N, N), dtype=np.float32)
+
+# Transfer data to GPU
+A_device = cuda.to_device(A)
+B_device = cuda.to_device(B)
+C_device = cuda.device_array((N, N), dtype=np.float32)
+
+# Define thread/block layout
+threads_per_block = (16, 16)
+blocks_per_grid_x = int(np.ceil(C.shape[0] / threads_per_block[0]))
+blocks_per_grid_y = int(np.ceil(C.shape[1] / threads_per_block[1]))
+blocks_per_grid = (blocks_per_grid_x, blocks_per_grid_y)
+
+# Measure start time
+start_time = time.time()
+
+# Launch the kernel
+matrix_mult[blocks_per_grid, threads_per_block](A_device, B_device, C_device)
+
+# Copy result back to host
+C = C_device.copy_to_host()
+print("Matrix multiplication result:")
+print(C)
+
+# Wait for the GPU to finish
+cuda.synchronize()
+
+# Measure end time
+end_time = time.time()
+
+# Print elapsed time
+print(f"Time taken for GPU computation: {end_time - start_time:.6f} seconds")
+
diff --git a/test-mig-master/Dockerfile b/test-mig-master/Dockerfile
new file mode 100644
index 0000000000000000000000000000000000000000..69ec7d307c24630bd48c6c2acf0201deadd62e85
--- /dev/null
+++ b/test-mig-master/Dockerfile
@@ -0,0 +1,15 @@
+FROM nvidia/cuda:12.6.1-base-ubuntu22.04
+
+# Install Python and required libraries
+RUN apt-get update && apt-get install -y python3 python3-pip && \
+    pip3 install numba numpy && \
+    apt-get clean
+
+# Copy the Python script into the container
+COPY gpu_test.py /app/gpu_test.py
+
+# Set the working directory
+WORKDIR /app
+
+# Command to run the script
+CMD ["python3", "gpu_test.py"]
diff --git a/test-mig-master/mig-test.yaml b/test-mig-master/mig-test.yaml
new file mode 100644
index 0000000000000000000000000000000000000000..659355752d4243128babdbaa005e3c82366974b4
--- /dev/null
+++ b/test-mig-master/mig-test.yaml
@@ -0,0 +1,12 @@
+apiVersion: v1
+kind: Pod
+metadata:
+  name: mig-test
+spec:
+  containers:
+  - name: gpu-container
+    image: nvidia/cuda:12.6.1-base-ubuntu22.04
+    command: ["nvidia-smi", "sleep", "3600"]
+    resources:
+      limits:
+        nvidia.com/mig-1g.11gb: 1