classifier module¶
CharGer¶
- class CharGer(config)[source]¶
Bases:
objectVariant classifier.
- Parameters
config (charger.config.CharGerConfig) – CharGer’s configurations. See
CharGerConfigfor details to set it up.
Examples
>>> config = CharGerConfig(...) >>> charger = CharGer() >>> charger.setup() >>> charger.run_acmg_modules() >>> charger.run_charger_modules()
- config: Final[charger.config.CharGerConfig]¶
Configuration as a
CharGerConfigobject.
- input_variants: List[charger.variant.Variant]¶
Parsed input variants.
- pathogenic_variants: List[charger.variant.Variant]¶
Known pathogenic variants.
- inheritance_genes: charger.classifier.InheritanceGenesType¶
Variant inheritance dominance mode of the genes for PVS1 module.
- results: List[charger.result.CharGerResult]¶
Classification results of the input variants. The length and order should always be the same as
input_variants.
- setup()[source]¶
Setup all the intput data and annotation.
Sequentially it calls:
_validate_config()_read_input_variants()_read_pathogenic_variants()_read_inheritance_gene_table()_read_pp2_gene_list()_read_bp1_gene_list()_match_clinvar()
- Return type
- run_acmg_modules()[source]¶
Run all ACMG modules.
See
acmg_modulesfor all the currently implemented modules.- Return type
- run_charger_modules()[source]¶
Run all CharGer customized modules.
See
custom_modulesfor all the currently implemented modules.- Return type
Module helper classes¶
- InheritanceGenesType¶
Type hint alias for
CharGer.inheritance_genes.alias of
Dict[str,Optional[charger.variant.GeneInheritanceMode]]
- class ModuleAvailability(value)[source]¶
Bases:
enum.EnumAvailability of a ACMG or CharGer modules.
Used by
CharGer._acmg_module_availabilityandCharGer._charger_module_availability.Examples
Skip PVS1 module by:
>>> charger = CharGer(CharGerConfig()) >>> charger._acmg_module_availability = ModuleAvailability.USER_DISABLED
- ACTIVE = 1¶
The module is active.
- USER_DISABLED = 2¶
The module is disabled by user. The module will be skipped.
- INVALID_SETUP = 3¶
The module has invalid setup, such as no additional annotation provided. The module will be skipped.