Open patricksttan opened 7 years ago
We got all the ktrans images in numpy format now. You can visualise them by the normal matplot command. The problem we have now is:
scan_directory = 'ProstateXKtrains-train-fixed/ProstateX-0000/ProstateX-0000-Ktrans.mhd'
img = sitk.ReadImage(scan_directory)
img.GetSpacing()
output:
(1.5, 1.5, 3.0)
From the result, I think the voxel size is above. Right?
I think it means that it is the voxel size for that image. 😉 For checking the voxel size of all the images, you can check the file datachecks.py, this has the method check_equal_voxel_size. It only checks the dicom files now but maybe you can modify it for the ktrans images.
Already made ktrans lesion visualisable with ktrans_example_check.py
in branch 'ktrans_work'.
Sub-steps now.
[x] Fix errors in the image plot. It has problems now that show the wrong size.
[x] Histogram plotting and understand the information in them.
[x] Back to main step normalization.
So I have taken the existing h5_converter and manage to join the ktrans data for both the train and the test set. I think this is useful torwards the momento we want to work with all data.
In order to do so the easiest way possible, I created two new directories: one for the all the train data and another for all the test data. This can be done by running join_all_data.unify_data.py
but it takes an awful amount of time. That's why I'll leave bellow the links to .zip
files containing these newly arranged directories.
I've also uploaded the new HDF5 datasets for the train and the test data (output of join_all_data.h5_converter_all.py
) and the new .csv
files (output of join_all_data.csv_fix_all.py
).
Here are all the links:
There is something wrong with the .hdf5 test data. Cannot get test data from it properly.
The problem with the .hdf5 test data is solved. The code is updated and the .csv
file as well (that's where the problem was). The .hdf5 test data will be updated as soon as possible (I'm having problems uploading it)
We have to find out if they can be used and if so, how.
[x] Make Ktrans hdf5 file available.
[x] Open K-trans files
[x] Visualize K-trans files
[x] Put K-trans files in an input array
[x] Get the exact lesion area.
[x] Normalise the data.
[x] Train a network using K-trans files
To solve now!
Improvements could be tried:
[ ] Try to clip in the whole image.
[x] Check the 0.0 case