diff options
author | Pjotr Prins | 2024-04-01 07:24:46 -0500 |
---|---|---|
committer | Frederick Muriuki Muriithi | 2024-09-12 07:31:52 -0500 |
commit | 644100ea2e5e407eb06ccb292d85dd20b104beee (patch) | |
tree | 829b2e96885de2f6cb7284513ae1f5958dd2fcf0 /gn3/computations | |
parent | de36e1fb9c39f6a644af3432b45d9297cd7cf42f (diff) | |
download | genenetwork3-644100ea2e5e407eb06ccb292d85dd20b104beee.tar.gz |
Getting Rqtl to run on fallback
Diffstat (limited to 'gn3/computations')
-rw-r--r-- | gn3/computations/rqtl.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/gn3/computations/rqtl.py b/gn3/computations/rqtl.py index f082482..8b1b316 100644 --- a/gn3/computations/rqtl.py +++ b/gn3/computations/rqtl.py @@ -1,5 +1,7 @@ """Procedures related to R/qtl computations""" import os +import sys +import logging from bisect import bisect from typing import Dict, List, Tuple, Union @@ -9,8 +11,9 @@ from flask import current_app from gn3.commands import compose_rqtl_cmd from gn3.computations.gemma import generate_hash_of_string -from gn3.fs_helpers import get_hash_of_files +from gn3.fs_helpers import get_hash_of_files, assert_path_exists +from gn3.debug import __pk__ def generate_rqtl_cmd( rqtl_wrapper_cmd: str, @@ -21,6 +24,8 @@ def generate_rqtl_cmd( dict of keyword arguments, return the full rqtl_wrapper command and an output filename generated from a hash of the genotype and phenotype files""" + assert_path_exists(rqtl_wrapper_cmd) + # Generate a hash from contents of the genotype and phenotype files _hash = get_hash_of_files( [v for k, v in rqtl_wrapper_kwargs.items() if k in ["g", "p"]] @@ -60,6 +65,7 @@ def process_rqtl_mapping(file_name: str) -> List: """Given an output file name, read in R/qtl results and return a List of marker objects""" marker_obs = [] + # Later I should probably redo this using csv.read to avoid the # awkwardness with removing quotes with [1:-1] with open( |