Closed lauravaldes98 closed 3 years ago
you need a mask. please read the IBSI document on what radiomics are.
in terms of input format I think the image needs to be an SITK object or a supported file format.
@lauravaldes98, how do you apply wavelets? If you are using pywavelets, you can also use it's implementation in PyRadiomics, via the waverley filter. Single DICOM images are readable by SimpleITK, though you need to convert to e.g. nrrd if you have a stack of DICOMs forming a 3D volume.
Hello, I Finally could apply the feature extraction using the FeatureExtractor, now i´m trying to prove some wavelets filters, but i'm having some troubles. This is the part of the code where I calculate the wavelets coeficients in the image and the mask
_extractor = featureextractor.RadiomicsFeatureExtractor(**settings) imagetype_dic = {'Original': None, 'Wavelet':{'wavelet':['db1']}, 'LoG': None, 'Square': None, 'SquareRoot': None, 'Logarithm': None, 'Exponential': None, 'Gradient': None, 'LBP3D': None} for imagetype in imagetype_dic: extractor.enableImageTypeByName(imagetype, customArgs=imagetype_dic[imagetype]) resultsdic = extractor.execute(image, mask)
and I'm having this error: 850 for i in range(0, start_level): # if start_level = 0 (default) this for loop never gets executed pywt_extensions_pywt.pyx in pywt._extensions._pywt.Wavelet.cinit() AttributeError: 'list' object has no attribute 'lower'
I try to change start_level and level atributes in the Wavelet but it doesn't work. Thank you so much for your help
It has nothing to do with start_level. It's in your custom settings, as you can only define 1 wavelet type, not a list of types.
extractor = featureextractor.RadiomicsFeatureExtractor(**settings)
imagetype_dic = {'Original': None,
'Wavelet':{'wavelet':['db1']}, # This is your error, it should read 'Wavelet':{'wavelet':'db1'}
'LoG': None,
'Square': None,
'SquareRoot': None,
'Logarithm': None,
'Exponential': None,
'Gradient': None,
'LBP3D': None}
for imagetype in imagetype_dic:
extractor.enableImageTypeByName(imagetype, customArgs=imagetype_dic[imagetype])
results_dic = extractor.execute(image, mask)
Hello, I´m working with DICOM ultrasound images, and I need to calculate texture features from this images. Before that, I apply some filters based on wavelets, so the final image is a numpy.ndarray type. I want to know if is possible use the FeatureExtractor in this numpy.ndarray and if is necessry to use a mask. Thanks!