-
Notifications
You must be signed in to change notification settings - Fork 33
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GPU Version #83
base: master
Are you sure you want to change the base?
GPU Version #83
Conversation
I merged my branch with the actual master. I disabled the use of textures to try first without textures. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi, I've tried the cuda implementation on the tutorial dataset using "VolumeFractions" model specifying ndirs=1 in both trk2dictionay.run and when generating the kernel but the fitting returns all Nan as streamlines weights and the IC map is empty.
I used the compartment_IC as DWI, created in a previous run using the usual cpu version of COMMIT.
Result using COMMIT cpu:
-> Fit model:
[ 00h 00m 50s ]
-> Saving results to "Results_VolumeFractions/*":
* Fitting errors:
- RMSE... [ 0.001 +/- 0.001 ]
- NRMSE... [ 0.071 +/- 9.243 ]
* Voxelwise contributions:
- Intra-axonal... [ OK ]
- Extra-axonal... [ OK ]
- Isotropic... [ OK ]
* Configuration and results:
- streamline_weights.txt... [ OK ]
- results.pickle... [ OK ]
Result using COMMIT gpu:
-> Fit model:
[ 00h 00m 00s ]
-> Saving results to "Results_VolumeFractions/*":
* Fitting errors:
- RMSE... [ 0.425 +/- 0.196 ]
- NRMSE... [ 0.974 +/- 0.159 ]
* Voxelwise contributions:
- Intra-axonal... [ OK ]
- Extra-axonal... [ OK ]
- Isotropic... [ OK ]
* Configuration and results:
- streamline_weights.txt... [ OK ]
The CUDA implementation works only for CylinderZeppelinBall model. I did not try with VolumeFraction. I tried with StickZeppelinBall but there was not improvement compared with CPU. In the meanwhile, I could add a flag to check the selected model and show a an error message when a model different than CylinderZeppelinBall is selected with CUDA. Then, we can add an efficient implementation for VolumeFraction. |
How difficult would it be to enable CUDA parallelization also for other models? Als, and most importantly, how fast do you think it will be according to the current implementation? |
It would not be so difficult to add support for VolumeFraction as it is simpler than CylinderZeppelinBall model. However, these weeks I'm a very busy with school and work until the first week of December. In the meanwhile, I could add a flag to check the selected model and make sure that CUDA is enabled only when CylinderZeppelinBall model is selected. Therefore, we would be able to submit something to ISMRM (without VolumeFraction experiments). I would prefer to wait until December to add the support for VolumeFraction properly. I think, for large datasets, we would be able to have similar speedups compared with the CylinderZeppelinBall model. But, for small datasets, the parallel CPU version is much faster because the transference of data between CPU and GPU is a bottleneck. |
No description provided.