class FeatureSpatialOutputSpec(TraitedSpec): edge_fraction = traits.Array( desc= "Array of the edge fraction feature scores for the components of the melIC file" ) csf_fraction = traits.Array( desc= "Array of the CSF fraction feature scores for the components of the melIC file" )
class TFRmorletInputSpec(BaseInterfaceInputSpec): """Input specification.""" epo_file = traits.File(exists=True, desc='epochs file in .fif format', mandatory=True) freqs = traits.Array(exists=True, desc='frequencies in Hz', mandatory=True) n_cycles = traits.Array( desc='the number of cycles globally or for each frequency') # noqa
class ClassificationInputSpec(BaseInterfaceInputSpec): maxRPcorr = traits.Array( desc= "Array of the 'maximum RP correlation' feature scores of the components" ) edge_fraction = traits.Array( desc="Array of the 'edge fraction' feature scores of the components") HFC = traits.Array( desc= "Array of the 'high-frequency content' feature scores of the components" ) csf_fraction = traits.Array( desc="Array of the 'CSF fraction' feature scores of the components")
class CoherenceAnalyzerOutputSpec(TraitedSpec): coherence_array = traits.Array(desc=('The pairwise coherence values' 'between the ROIs')) timedelay_array = traits.Array(desc=('The pairwise time delays between the' 'ROIs (in seconds)')) coherence_csv = File(desc=('A csv file containing the pairwise ' 'coherence values')) timedelay_csv = File(desc=('A csv file containing the pairwise ' 'time delay values')) coherence_fig = File(desc=('Figure representing coherence values')) timedelay_fig = File(desc=('Figure representing coherence values'))
class LungSegmentationInferenceInputSpec(BaseInterfaceInputSpec): tensor = traits.Array(desc='Tensor to be fed to the network.') image_info = traits.Dict( desc='Dictionary with information about the image.') weights = traits.List(desc='List of network weights.') outdir = Directory('segmented', usedefault=True, desc='Folder to store the preprocessing results.')
class ClassificationOutputSpec(TraitedSpec): motionICs = traits.Array( desc= "Array containing the indices of the components identified as motion components" ) classified_motion_ics = traits.File( desc= "A text file containing the indices of the components identified as motion components" )
class PreprocessingOutputSpec(TraitedSpec): preprocessed_array = traits.Array( desc='preprocessed images (FLAIR only or T1 and FLAIR) as Numpy array') slice_shape = traits.Tuple((traits.Int(), traits.Int(), traits.Int()), desc='slice shape') # ToDo: implement save npz flair_array_npy = File(desc='preprocessed FLAIR as Numpy .npz')
class TrainSVMInputSpec(BaseInterfaceInputSpec): inputs = File(exists=True, desc='input values for training', mandatory=True) targets = File(exists=True, desc='target values for training', mandatory=True) indices = traits.Array(desc='indices for inputs and targets', mandatory=False)
class SignalPredictionInputSpec(BaseInterfaceInputSpec): aligned_dwis = InputMultiObject(File(exists=True)) aligned_bvecs = traits.Either(InputMultiObject(File(exists=True)), traits.Array) bvals = traits.Either(InputMultiObject(File(exists=True)), traits.Array) aligned_mask = File(exists=True, mandatory=True) aligned_b0_mean = File(exists=True, mandatory=True) bvec_to_predict = traits.Array() bval_to_predict = traits.Float() minimal_q_distance = traits.Float(2.0, usedefault=True) model = traits.Str('3dSHORE', usedefault=True)
class PredictInputSpec(BaseInterfaceInputSpec): slice_shape = traits.Tuple((traits.Int(), traits.Int(), traits.Int()), desc='slice shape') preprocessed_array = traits.Array( mandatory=True, desc='Array from preprocessed FLAIR and T1w') weights = traits.List(File(exists=True, ), mandatory=True, desc='Weights as list of H5 files')
class _PlotFuncInputSpec(BaseInterfaceInputSpec): """Input interface wrapper for PlotFunc""" conn_matrix = traits.Array(mandatory=True) conn_model = traits.Str(mandatory=True) atlas = traits.Any() dir_path = Directory(exists=True, mandatory=True) ID = traits.Any(mandatory=True) network = traits.Any() labels = traits.Array(mandatory=True) roi = traits.Any() coords = traits.Array(mandatory=True) thr = traits.Any() node_size = traits.Any() edge_threshold = traits.Any() smooth = traits.Any() prune = traits.Any() uatlas = traits.Any() c_boot = traits.Any() norm = traits.Any() binary = traits.Bool() hpass = traits.Any()
class PostprocessingInputSpec(BaseInterfaceInputSpec): flair = File(exists=True, mandatory=True, desc='Input FLAIR in an ITK readable format') prediction = traits.Array(mandatory=True, desc='prediction to reshape') rows_standard = traits.Int(mandatory=True, desc='input size for rows') cols_standard = traits.Int(mandatory=True, desc='input size for columns') per = traits.Float(mandatory=True, desc='ratio')
class _PlotStructInputSpec(BaseInterfaceInputSpec): """Input interface wrapper for PlotStruct""" conn_matrix = traits.Array(mandatory=True) conn_model = traits.Str(mandatory=True) atlas = traits.Any() dir_path = Directory(exists=True, mandatory=True) ID = traits.Any(mandatory=True) network = traits.Any() labels = traits.Array(mandatory=True) roi = traits.Any() coords = traits.Array(mandatory=True) thr = traits.Any() node_size = traits.Any() edge_threshold = traits.Any() prune = traits.Any() uatlas = traits.Any() target_samples = traits.Any() norm = traits.Any() binary = traits.Bool() track_type = traits.Any() directget = traits.Any() min_length = traits.Any()
class _PlotStructInputSpec(BaseInterfaceInputSpec): """Input interface wrapper for PlotStruct""" conn_matrix = traits.Any() conn_model = traits.Str(mandatory=True) atlas = traits.Any(mandatory=False) dir_path = Directory(exists=True, mandatory=True) ID = traits.Any(mandatory=True) subnet = traits.Any(mandatory=True) labels = traits.Array(mandatory=True) roi = traits.Any(mandatory=True) coords = traits.Array(mandatory=True) thr = traits.Any(mandatory=True) node_radius = traits.Any(mandatory=True) edge_threshold = traits.Any(mandatory=True) prune = traits.Any(mandatory=True) parcellation = traits.Any(mandatory=False) norm = traits.Any(mandatory=True) binary = traits.Bool(mandatory=True) track_type = traits.Any(mandatory=True) traversal = traits.Any(mandatory=True) min_length = traits.Any(mandatory=True) error_margin = traits.Any(mandatory=True)
class _PlotFuncInputSpec(BaseInterfaceInputSpec): """Input interface wrapper for PlotFunc""" conn_matrix = traits.Any() conn_model = traits.Str(mandatory=True) atlas = traits.Any(mandatory=False) dir_path = Directory(exists=True, mandatory=True) ID = traits.Any(mandatory=True) subnet = traits.Any(mandatory=True) labels = traits.Array(mandatory=True) roi = traits.Any(mandatory=True) coords = traits.Array(mandatory=True) thr = traits.Any(mandatory=True) node_radius = traits.Any(mandatory=True) edge_threshold = traits.Any(mandatory=True) smooth = traits.Any(mandatory=True) prune = traits.Any(mandatory=True) parcellation = traits.Any(mandatory=False) norm = traits.Any(mandatory=True) binary = traits.Bool(mandatory=True) hpass = traits.Any(mandatory=True) signal = traits.Any(mandatory=True) edge_color_override = traits.Bool(mandatory=True)
class TrainInputSpec(BaseInterfaceInputSpec): images = traits.Array(mandatory=True, desc='Images for the training as NumPy array') masks = traits.Array(mandatory=True, desc='Masks for training as NumPy array') model_path = traits.Directory(mandatory=True, desc='directory where to save the models') ensemble_parameter = traits.Int(3, usedefault=True, desc='ensemble parameter') verbose = traits.Bool(True, usedefault=True, desc='Verbose') batch_size = traits.Int(30, usedefault=True, desc='batch size, default 30') epochs = traits.Int(5, usedefault=True, desc='epochs, default 5') image_shape = traits.Tuple((traits.Int(), traits.Int(), traits.Int()), desc='slice shape') shuffle = traits.Bool(True, desc='shuffle')
class LungSegmentationPreprocOutputSpec(TraitedSpec): preproc_image = traits.File(exists=True, desc='Preprocessed image') tensor = traits.Array(desc='Tensor to be fed to the network.') image_info = traits.Dict( desc='Dictionary with information about the image.')
class PostprocessingOutputSpec(TraitedSpec): postprocessed_prediction = traits.Array( desc='get prediction in original shape')
class TestSVMInputSpec(BaseInterfaceInputSpec): svm = File(exists=True, desc='SVM to be tested', mandatory=True) inputs = traits.Array(desc='input values to be tested', mandatory=True) targets = traits.Array(desc='target values to be tested', mandatory=True) indices = traits.Array(desc='indices for inputs and targets', mandatory=False)
class PredictOutputSpec(TraitedSpec): prediction = traits.Array(desc='Prediction as array') prediction_npy = traits.File(desc='Prediction as Numpy .npy')
class FeatureFrequencyOutputSpec(TraitedSpec): HFC = traits.Array( desc= "Array of the HFC ('High-frequency content') feature scores for the components of the melodic_FTmix file" )
class SavePredictionInputSpec(BaseInterfaceInputSpec): prediction_array = traits.Array(mandatory=True, desc='prediction as array') output_filename = traits.Str('prediction', usedefault=True, desc='output filename')
class EnsembleInputSpec(BaseInterfaceInputSpec): in_arrays = traits.List(traits.Array(), mandatory=True, desc='Arrays list to esemble')
class FeatureTimeSeriesOutputSpec(TraitedSpec): maxRPcorr = traits.Array( desc= "Array of the maximum RP correlation feature scores for the components of the melodic_mix file" )
class EnsembleOutputSpec(TraitedSpec): out_array = traits.Array(desc='averaged array')
class SplitB0DWIsFromFileOutputSpec(TraitedSpec): out_B0s = OutputMultiPath(File(exists=True)) out_DWIs = OutputMultiPath(File(exists=True)) out_all = OutputMultiPath(File(exists=True)) out_indices = traits.Array(desc="B0 Indices in the table")
class ThresholdingInputSpec(BaseInterfaceInputSpec): in_array = traits.Array(mandatory=True, desc='input array') thres = traits.Float(default_value=0.5, usedefault=True, desc='threshold')
class WriteArrayToCsvInputSpec(BaseInterfaceInputSpec): in_array = traits.Array(exists=True, mandatory=True, desc="array") in_name = traits.String(mandatory=True, desc="Name of the output file")
class ExtractAffineOutputSpec(TraitedSpec): out_matrix = traits.Array(desc='The affine matrix as NumPy array') out_file = File(desc='A text file containing the affine matrix')
class ThresholdingOutputSpec(TraitedSpec): out_array = traits.Array(desc='thresholded array')