aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPjotr Prins2015-04-19 11:54:42 +0200
committerPjotr Prins2015-04-19 11:54:42 +0200
commitac57e839c8ffb52f65e74a9064e4adeb15c76b49 (patch)
tree979d57b2bc608761073c749783bdd9d50d51b9d0
parente7cbe10d754e1e334746fc43a01e8b9fa3a666c0 (diff)
downloadgenenetwork2-ac57e839c8ffb52f65e74a9064e4adeb15c76b49.tar.gz
pylmm: module loading
-rw-r--r--wqflask/wqflask/my_pylmm/pyLMM/lmm.py38
-rw-r--r--wqflask/wqflask/my_pylmm/pyLMM/lmm2.py2
2 files changed, 19 insertions, 21 deletions
diff --git a/wqflask/wqflask/my_pylmm/pyLMM/lmm.py b/wqflask/wqflask/my_pylmm/pyLMM/lmm.py
index 5b06c9ae..135ba1f4 100644
--- a/wqflask/wqflask/my_pylmm/pyLMM/lmm.py
+++ b/wqflask/wqflask/my_pylmm/pyLMM/lmm.py
@@ -19,48 +19,46 @@ from __future__ import absolute_import, print_function, division
import sys
import time
-import argparse
+# import argparse
import uuid
import numpy as np
from scipy import linalg
from scipy import optimize
from scipy import stats
-import pdb
+# import pdb
-import simplejson as json
-
-import gzip
-import zlib
+# import gzip
+# import zlib
import datetime
-import cPickle as pickle
-import simplejson as json
-
+# import cPickle as pickle
from pprint import pformat as pf
-from redis import Redis
-Redis = Redis()
-
-import sys
-
-from utility.benchmark import Bench
-from utility import temp_data
-
+# pylmm imports
from kinship import kinship, kinship_full, kvakve
import genotype
import phenotype
import gwas
+from benchmark import Bench
+
+# The following imports are for exchanging data with the webserver
+import simplejson as json
+from redis import Redis
+Redis = Redis()
+from utility import temp_data
+
+has_gn2=None
-has_gn2=True
-sys.stderr.write("INFO: pylmm system path is "+":".join(sys.path)+"\n")
+# sys.stderr.write("INFO: pylmm system path is "+":".join(sys.path)+"\n")
sys.stderr.write("INFO: pylmm file is "+__file__+"\n")
# ---- A trick to decide on the environment:
try:
- sys.stderr.write("INFO: trying loading module\n")
+ sys.stderr.write("INFO: lmm try loading module\n")
import utility.formatting # this is never used, just to check the environment
sys.stderr.write("INFO: This is a genenetwork2 environment\n")
from gn2 import uses, progress_set_func
+ has_gn2=True
except ImportError:
# Failed to load gn2
has_gn2=False
diff --git a/wqflask/wqflask/my_pylmm/pyLMM/lmm2.py b/wqflask/wqflask/my_pylmm/pyLMM/lmm2.py
index c65843ec..d871d8d2 100644
--- a/wqflask/wqflask/my_pylmm/pyLMM/lmm2.py
+++ b/wqflask/wqflask/my_pylmm/pyLMM/lmm2.py
@@ -29,7 +29,7 @@ sys.stderr.write("INFO: pylmm (lmm2) file is "+__file__+"\n")
# ---- A trick to decide on the environment:
try:
- sys.stderr.write("INFO: trying loading module\n")
+ sys.stderr.write("INFO: lmm2 try loading module\n")
import utility.formatting # this is never used, just to check the environment
sys.stderr.write("INFO: This is a genenetwork2 environment (lmm2)\n")
from gn2 import uses, progress_set_func