immuneML.dsl.instruction_parsers package¶
Submodules¶
immuneML.dsl.instruction_parsers.ApplyGenModelParser module¶
- class immuneML.dsl.instruction_parsers.ApplyGenModelParser.ApplyGenModelParser[source]¶
Bases:
object
Specification example for the ApplyGenModel instruction:
instruction_name: type: ApplyGenModel gen_examples_count: 100 ml_config_path: ./config.zip reports: [data_rep1, ml_rep2]
- parse(key: str, instruction: dict, symbol_table: SymbolTable, path: Path = None) ApplyGenModelInstruction [source]¶
immuneML.dsl.instruction_parsers.ClusteringParser module¶
- class immuneML.dsl.instruction_parsers.ClusteringParser.ClusteringParser[source]¶
Bases:
object
- parse(key: str, instruction: dict, symbol_table: SymbolTable, path: Path = None) ClusteringInstruction [source]¶
- immuneML.dsl.instruction_parsers.ClusteringParser.make_encoder_obj(symbol_table, encoding_key, dataset_key)[source]¶
- immuneML.dsl.instruction_parsers.ClusteringParser.make_setting_obj(setting, valid_encodings, valid_clusterings, valid_dim_red, symbol_table, instruction)[source]¶
- immuneML.dsl.instruction_parsers.ClusteringParser.parse_clustering_settings(key: str, instruction: dict, symbol_table: SymbolTable) List[ClusteringSetting] [source]¶
- immuneML.dsl.instruction_parsers.ClusteringParser.parse_labels(key, instruction, dataset) LabelConfiguration [source]¶
- immuneML.dsl.instruction_parsers.ClusteringParser.parse_metrics(key: str, instruction: dict, symbol_table: SymbolTable) List[str] [source]¶
- immuneML.dsl.instruction_parsers.ClusteringParser.parse_reports(key, instruction, symbol_table) List[Report] [source]¶
- immuneML.dsl.instruction_parsers.ClusteringParser.parse_split_config(key, instruction, symbol_table) SplitConfig [source]¶
immuneML.dsl.instruction_parsers.DatasetExportParser module¶
- class immuneML.dsl.instruction_parsers.DatasetExportParser.DatasetExportParser[source]¶
Bases:
object
Specification of instruction with a random datasets:
- definitions:
- datasets:
- my_generated_dataset: # a dataset to be exported in the given format
format: RandomRepertoireDataset params:
result_path: generated_dataset/ repertoire_count: 100 sequence_count_probabilities:
100: 0.5 120: 0.5
- sequence_length_probabilities:
12: 0.333 13: 0.333 14: 0.333
- labels:
- immune_event_1:
yes: 0.5 no: 0.5
- preprocessing_sequences:
- my_preprocessing:
- my_filter:
- ClonesPerRepertoireFilter:
lower_limit: 110 upper_limit: 200
- instructions:
- my_instruction1: # instruction name
type: DatasetExport datasets: # list of datasets to export
my_generated_dataset
preprocessing_sequence: my_preprocessing_sequence number_of_processes: 4 export_formats: # list of formats to export the datasets to
AIRR
- OPTIONAL_KEYS = ['preprocessing_sequence', 'number_of_processes']¶
- REQUIRED_KEYS = ['type', 'datasets', 'export_formats']¶
- parse(key: str, instruction: dict, symbol_table: SymbolTable, path: Path = None) DatasetExportInstruction [source]¶
immuneML.dsl.instruction_parsers.ExploratoryAnalysisParser module¶
- class immuneML.dsl.instruction_parsers.ExploratoryAnalysisParser.ExploratoryAnalysisParser[source]¶
Bases:
object
The specification consists of a list of analyses that need to be performed;
Each analysis is defined by a dataset identifier, a report identifier and optionally encoding and labels and are loaded into ExploratoryAnalysisUnit objects;
DSL example for ExploratoryAnalysisInstruction assuming that d1, p1, r1, r2, e1, w1 are defined previously in definitions section:
instruction_name: type: ExploratoryAnalysis number_of_processes: 4 analyses: my_first_analysis: # simple analysis running a report on a dataset dataset: d1 report: r1 my_second_analysis: # more complicated analysis; including preprocessing, encoding, example weighting and running a report dataset: d1 preprocessing_sequence: p1 encoding: e1 example_weighting: w1 report: r2 labels: - CD - CMV
- parse(key: str, instruction: dict, symbol_table: SymbolTable, path: Path = None) ExploratoryAnalysisInstruction [source]¶
immuneML.dsl.instruction_parsers.FeasibilitySummaryParser module¶
- class immuneML.dsl.instruction_parsers.FeasibilitySummaryParser.FeasibilitySummaryParser[source]¶
Bases:
object
- parse(key: str, instruction: dict, symbol_table: SymbolTable, path: Path = None) FeasibilitySummaryInstruction [source]¶
immuneML.dsl.instruction_parsers.LabelHelper module¶
immuneML.dsl.instruction_parsers.LigoSimParser module¶
- class immuneML.dsl.instruction_parsers.LigoSimParser.LigoSimParser[source]¶
Bases:
object
- parse(key: str, instruction: dict, symbol_table: SymbolTable, path: Path = None) LigoSimInstruction [source]¶
immuneML.dsl.instruction_parsers.MLApplicationParser module¶
- class immuneML.dsl.instruction_parsers.MLApplicationParser.MLApplicationParser[source]¶
Bases:
object
Specification example for the MLApplication instruction:
instruction_name: type: MLApplication dataset: d1 config_path: ./config.zip metrics: - accuracy - precision - recall number_of_processes: 4
- parse(key: str, instruction: dict, symbol_table: SymbolTable, path: Path) MLApplicationInstruction [source]¶
immuneML.dsl.instruction_parsers.SubsamplingParser module¶
- class immuneML.dsl.instruction_parsers.SubsamplingParser.SubsamplingParser[source]¶
Bases:
object
- parse(key: str, instruction: dict, symbol_table: SymbolTable, path: Path = None) SubsamplingInstruction [source]¶
immuneML.dsl.instruction_parsers.TrainGenModelParser module¶
- class immuneML.dsl.instruction_parsers.TrainGenModelParser.TrainGenModelParser[source]¶
Bases:
object
- parse(key: str, instruction: dict, symbol_table: SymbolTable, path: Path = None) TrainGenModelInstruction [source]¶
immuneML.dsl.instruction_parsers.TrainMLModelParser module¶
- class immuneML.dsl.instruction_parsers.TrainMLModelParser.TrainMLModelParser[source]¶
Bases:
object
- parse(key: str, instruction: dict, symbol_table: SymbolTable, path: Path = None) TrainMLModelInstruction [source]¶