diff options
author | Pjotr Prins | 2016-02-24 16:34:52 +0000 |
---|---|---|
committer | Pjotr Prins | 2016-04-20 09:28:22 +0000 |
commit | 575e00b1061c58952cba38af5ab078ca0081b4d7 (patch) | |
tree | e51b160a262ebe83785ad6fd9f36f1156733dd34 | |
parent | 1e9d7476697bf8b60ab1004f25b295f81d94de49 (diff) | |
download | genenetwork2-575e00b1061c58952cba38af5ab078ca0081b4d7.tar.gz |
[PATCH 041/100] Fixes for running tools
-rw-r--r-- | etc/default_settings.py | 6 | ||||
-rw-r--r-- | wqflask/utility/tools.py | 4 | ||||
-rw-r--r-- | wqflask/wqflask/marker_regression/marker_regression.py | 3 | ||||
-rw-r--r-- | wqflask/wqflask/marker_regression/marker_regression_gn1.py | 7 |
4 files changed, 10 insertions, 10 deletions
diff --git a/etc/default_settings.py b/etc/default_settings.py index 6a218f26..60a3a7b4 100644 --- a/etc/default_settings.py +++ b/etc/default_settings.py @@ -24,6 +24,6 @@ SECRET_HMAC_CODE = '\x08\xdf\xfa\x93N\x80\xd9\\H@\\\x9f`\x98d^\xb4a;\xc6OM\x946a # Path overrides for Genenetwork GENENETWORK_FILES = "../../gn2_data" -PYLMM_COMMAND = os.popen("which pylmm_redis").read() -PLINK_COMMAND = os.popen("which plink2").read() -GEMMA_COMMAND = os.popen("which gemma").read() +PYLMM_COMMAND = str.strip(os.popen("which pylmm_redis").read()) +PLINK_COMMAND = str.strip(os.popen("which plink2").read()) +GEMMA_COMMAND = str.strip(os.popen("which gemma").read()) diff --git a/wqflask/utility/tools.py b/wqflask/utility/tools.py index 67c5128a..51189fa3 100644 --- a/wqflask/utility/tools.py +++ b/wqflask/utility/tools.py @@ -133,7 +133,7 @@ def tempdir(): # Cached values PYLMM_COMMAND = pylmm_command() -GEMMA_COMMAND = pylmm_command() -PLINK_COMMAND = pylmm_command() +GEMMA_COMMAND = gemma_command() +PLINK_COMMAND = plink_command() FLAT_FILES = flat_files() TEMPDIR = tempdir() diff --git a/wqflask/wqflask/marker_regression/marker_regression.py b/wqflask/wqflask/marker_regression/marker_regression.py index 265f9473..910d0c3c 100644 --- a/wqflask/wqflask/marker_regression/marker_regression.py +++ b/wqflask/wqflask/marker_regression/marker_regression.py @@ -937,8 +937,7 @@ class MarkerRegression(object): Redis.expire(key, 60*60) print("before printing command") - command = PYLMM_COMMAND + ' --key {} --species {}'.format(key, - "other") + command = PYLMM_COMMAND + ' --key {} --species {}'.format(key, "other") print("command is:", command) print("after printing command") diff --git a/wqflask/wqflask/marker_regression/marker_regression_gn1.py b/wqflask/wqflask/marker_regression/marker_regression_gn1.py index decde579..4edc1891 100644 --- a/wqflask/wqflask/marker_regression/marker_regression_gn1.py +++ b/wqflask/wqflask/marker_regression/marker_regression_gn1.py @@ -28,6 +28,7 @@ import time import string from math import * import piddle as pid +import piddlePIL as pil import sys,os import cPickle import httplib, urllib @@ -551,7 +552,7 @@ class MarkerRegression(object): # showLocusForm = webqtlUtil.genRandStr("fm_") #else: showLocusForm = "" - intCanvas = pid.PILCanvas(size=(self.graphWidth, self.graphHeight)) + intCanvas = pil.PILCanvas(size=(self.graphWidth, self.graphHeight)) gifmap = self.plotIntMapping(intCanvas, startMb = self.startMb, endMb = self.endMb, showLocusForm= showLocusForm) self.gifmap = gifmap.__str__() @@ -563,7 +564,7 @@ class MarkerRegression(object): #Scales plot differently for high resolution if self.draw2X: - intCanvasX2 = pid.PILCanvas(size=(self.graphWidth*2,self.graphHeight*2)) + intCanvasX2 = pil.PILCanvas(size=(self.graphWidth*2,self.graphHeight*2)) gifmapX2 = self.plotIntMapping(intCanvasX2, startMb = self.startMb, endMb = self.endMb, showLocusForm= showLocusForm, zoom=2) intCanvasX2.save(os.path.join(webqtlConfig.GENERATED_IMAGE_DIR, self.filename+"X2"), format='png') #DLintImgX2=HT.Href(text='Download',url = '/image/'+self.filename+'X2.png', Class='smallsize', target='_blank') @@ -2582,7 +2583,7 @@ class MarkerRegression(object): ######################################### # Permutation Graph ######################################### - myCanvas = pid.PILCanvas(size=(400,300)) + myCanvas = pil.PILCanvas(size=(400,300)) if 'lod_score' in self.qtlresults[0] and self.LRS_LOD == "LRS": perm_output = [value*4.16 for value in self.perm_output] elif 'lod_score' not in self.qtlresults[0] and self.LRS_LOD == "LOD": |