This is a set of multiple notebooks which walks you through Clara train SDK features and capabilities.
There are multiple notebooks showing:
- AI Assisted Annotation
- Domain specific examples: Digital Pathology
- Hyper parameter optimization with AutoML
- Federated learning features
- Performance gains
** P.S.: Please refer to DeepHiveMind/NVIDIA-CLARA-Train-examples for better insight.
- Getting Started
- AI Assisted Annotation (AIAA):
- Basics
- Train Deepgrow (2D and 3D) (New in V4)
- OHIF Integration (New in V4)
- DataSets
- Download Decathlon Dataset (New in V4)
- Download from National Cancer Archive (New in V4)
- Federated Learning
- AutoML
- Domain specific Examples:
- Digital pathology (New in V4)
- Integration (coming soon)
- Setup on AWS
- End to End workflow
- Clara Train to Clara Deploy workflow
- Integration with XNAT
- One or more Nvidia GPU. (2+GPUS are recommended for advanced features as AutoML).
- If you already have docker installed then user should be in the docker group. Otherwise, sudo is needed to install the pre requisite
This NoteBooks contain:
- Scripts to:
- Install pre-requisite as Docker 19, docker compose
- Start pulling the clara docker and run jupyter lab.
- SampleData: To start using the sdk.
- Multiple Notebooks to show show all capabilities of the sdk
You should skip this step, if you already have cuda and nvida driver.
To check simply run nvidia-smi
If you don't have nvidia drivers / cuda installed or you do get a cuda lib mismatch when running nvidia-smi
as
nvidia-smi
Failed to initialize NVML: Driver/library version mismatch
then you need to do the following steps
sudo apt-get --purge remove "*nvidia*"
sudo apt autoremove
reboot using
sudo systemctl reboot
Got to https://developer.nvidia.com/cuda-11.0-download-archive?target_os=Linux pick your os and hardware and follow instructions
you need to reboot again after installing cuda
sudo systemctl reboot
run nvidia-smi
should show you the gpus you have on your system
If you already have docker 19+, nvidia docker, and docker compose you can skip this step. Otherwise, you can install docker and docker compose using script provided by
cd scripts
sudo installDocker.sh
To begin, go into the scripts folder
cd scripts
from here you can just start either:
./startClaraTrainNoteBooks.sh
to start docker compose of Triton used by AIAA and clara train container- Only clara train container for training, AutoML and FL workflow
run command below which will pull and start the latest clara train SDK and Triton server for AIAA.
./startClaraTrainNoteBooks.sh
You can now go to your browser on port 3030 and use the token printed out as below
[I 23:47:18.654 LabApp] http://claratrain:8888/?token=3e5ef35f982ea5a3e432322b07b6d33b5fc51a4fcb0ffa88
[I 23:47:18.654 LabApp] or http://127.0.0.1:8888/?token=3e5ef35f982ea5a3e432322b07b6d33b5fc51a4fcb0ffa88
You should edit the docker-compose.yml file in case you want to:
- start jupter lab on different port than 3030
- change the AIAA port as
ports:
- "3030:8888" # Jupyter lab port
- "3031:5000" # AIAA port
To expose certain gpus to Triton please uncomment lines at the end of the docker-compose file
capabilities: [ gpu ]
# To specify certain GPU uncomment line below
#device_ids: ['0,1']
- Install gpu monitoring tools for jupyter lab. You can install gpu monitoring tools (see step 5) by changing the line
##### use vanilla clara train docker
#image: nvcr.io/nvidia/clara-train-sdk:v4.0
##### to build image with GPU dashboard inside jupyter lab
build:
context: ./dockerWGPUDashboardPlugin/ # Project root
dockerfile: ./Dockerfile # Relative to context
image: clara-train-nvdashboard:v4.0
If you don't plan to use AIAA then only running clara train container without triton is sufficient. For this you need to run
startDocker.sh
Now you can go to your browser on the port you specified above (default is 3030) with the token provided in the terminal. You should see jupyter lab where you should start running the Welcome Notebook. This page shows all notebooks available as
Before starting, we need to activate the GPU Dashboard.
Look at the left sidebar and click on System Dashboards
.
Next, click on GPU Utilization
, GPU Memory
,GPU Resources
, and MachineResources
.
All of these will open in new tabs.
Click and hold on GPU Utilization
tab and drag it to the right most area of screen.
It will dock the tab on top of the notebook.
Follow the same procedure with GPU Memory
tab and docker it on the bottom right of screen.
The result should be similar to
Now we can see GPU Utilization and GPU Memory while we run through the notebooks.