Esempio n. 1
0
    def handle(self, *args, **options):

        if settings.CUSTOM_ANNOTATOR_SETTINGS is not None:
            print("Load dbNSFP.. ")

            # note that you could use mall.get_custom_annotator() here too
            custom_annotator = CustomAnnotator(settings.CUSTOM_ANNOTATOR_SETTINGS)
            custom_annotator.load()

        get_reference().load()
        mall.get_annotator().load()
Esempio n. 2
0
    def handle(self, *args, **options):

        if settings.CUSTOM_ANNOTATOR_SETTINGS is not None:
            print("Load dbNSFP.. ")

            # note that you could use mall.get_custom_annotator() here too
            custom_annotator = CustomAnnotator(
                settings.CUSTOM_ANNOTATOR_SETTINGS)
            custom_annotator.load()

        get_reference().load()
        mall.get_annotator().load()
Esempio n. 3
0
File: mall.py Progetto: zmcv/seqr
def get_custom_annotator():
    global _custom_annotator
    # custom annotator can be None
    if _custom_annotator is None and settings.CUSTOM_ANNOTATOR_SETTINGS:
        _custom_annotator = CustomAnnotator(settings.CUSTOM_ANNOTATOR_SETTINGS)

    return _custom_annotator
Esempio n. 4
0
        }
    except Exception as e:
        print("\nWARNING: unable to parse predictors from vep fields: %s. %s" %
              (vep_fields, e))
        return {}

    return annotations_dict


if __name__ == '__main__':
    parser = argparse.ArgumentParser()
    parser.add_argument('command')
    parser.add_argument('--settings')
    parser.add_argument('--vcf_file_list')
    parser.add_argument('--custom_annotator_settings')
    args = parser.parse_args()
    annotator_settings = imp.load_source('annotator_settings', args.settings)
    custom_annotator = None
    if args.custom_annotator_settings:
        custom_annotator_settings = imp.load_source(
            'custom_annotation_settings', args.custom_annotator_settings)
        custom_annotator = CustomAnnotator(custom_annotator_settings)
    annotator = VariantAnnotator(annotator_settings,
                                 custom_annotator=custom_annotator)
    if args.command == 'load':
        annotator.load()
    if args.command == 'add_vcf_files':
        vcf_file_paths = [l.strip() for l in open(args.vcf_file_list)]
        for vcf_path in vcf_file_paths:
            annotator.add_vcf_file_to_annotator(vcf_path)
Esempio n. 5
0
 def handle(self, *args, **options):
     _custom_annotator = CustomAnnotator(settings.CUSTOM_ANNOTATOR_SETTINGS)
     _custom_annotator.load()
Esempio n. 6
0
 def handle(self, *args, **options):
     _custom_annotator = CustomAnnotator(settings.CUSTOM_ANNOTATOR_SETTINGS)
     _custom_annotator.load()