# HG changeset patch # User francesco_lapi # Date 1741100863 0 # Node ID 91ad9bf5a7344caf702ec9077963087870123f99 # Parent 466172709d68c1c8ba785a91dc191c7e828823d3 Uploaded diff -r 466172709d68 -r 91ad9bf5a734 COBRAxy/ras_generator.py --- a/COBRAxy/ras_generator.py Tue Mar 04 15:05:13 2025 +0000 +++ b/COBRAxy/ras_generator.py Tue Mar 04 15:07:43 2025 +0000 @@ -221,7 +221,7 @@ collections.Counter(gene[gene.columns[0]]).items() if count > 1] pat_dup = [item for item, count in collections.Counter(list(gene.columns)).items() if count > 1] - gene_in_rule = None + if gene_dup: if gene_custom == None: if args.rules_selector == 'HMRcore': @@ -232,7 +232,9 @@ elif args.rules_selector == 'ENGRO2': gene_in_rule = pk.load(open(args.tool_dir + '/local/pickle files/ENGRO2_genes.p', 'rb')) - print(pk.load(open(args.tool_dir + '/local/pickle files/ENGRO2_genes.p', 'rb'))) + + gene_in_rule = pk.load(open(args.tool_dir + '/local/pickle files/ENGRO2_genes.p', 'rb')) + print(gene_in_rule) print(f"{args.tool_dir}/local/pickle files/ENGRO2_genes.p") utils.logWarning(f"{args.tool_dir}'/local/pickle files/ENGRO2_genes.p'", ARGS.out_log)