Commit 48f93c61 authored by Manuel Günther's avatar Manuel Günther
Browse files

Replaced '!= None' with 'is not None'; limited gridtk verbosity level to INFO

parent ef664d06
......@@ -94,7 +94,7 @@ def project(algorithm, extractor, groups = None, indices = None, force = False):
projected_files = fs.projected_list(groups=groups)
# select a subset of indices to iterate
if indices != None:
if indices is not None:
index_range = range(indices[0], indices[1])
logger.info("- Projection: splitting of index range %s", str(indices))
else:
......@@ -217,7 +217,7 @@ def enroll(algorithm, extractor, compute_zt_norm, indices = None, groups = ['dev
for group in groups:
model_ids = fs.model_ids(group)
if indices != None:
if indices is not None:
model_ids = model_ids[indices[0]:indices[1]]
logger.info("- Enrollment: splitting of index range %s", str(indices))
......@@ -248,7 +248,7 @@ def enroll(algorithm, extractor, compute_zt_norm, indices = None, groups = ['dev
for group in groups:
t_model_ids = fs.t_model_ids(group)
if indices != None:
if indices is not None:
t_model_ids = t_model_ids[indices[0]:indices[1]]
logger.info("- Enrollment: splitting of index range %s", str(indices))
......
......@@ -85,7 +85,7 @@ def extract(extractor, preprocessor, groups=None, indices = None, force = False)
feature_files = fs.feature_list(groups=groups)
# select a subset of indices to iterate
if indices != None:
if indices is not None:
index_range = range(indices[0], indices[1])
logger.info("- Extraction: splitting of index range %s" % str(indices))
else:
......
......@@ -63,7 +63,7 @@ class GridSubmission:
import gridtk
# setup logger
bob.core.log.set_verbosity_level(bob.core.log.setup("gridtk"), args.verbose)
bob.core.log.set_verbosity_level(bob.core.log.setup("gridtk"), min(args.verbose,2))
Manager = gridtk.local.JobManagerLocal if args.grid.is_local() else gridtk.sge.JobManagerSGE
self.job_manager = Manager(database = args.gridtk_database_file, wrapper_script=jman)
self.submitted_job_ids = []
......
......@@ -37,7 +37,7 @@ def preprocess(preprocessor, groups = None, indices = None, force = False):
preprocessed_data_files = fs.preprocessed_data_list(groups=groups)
# select a subset of keys to iterate
if indices != None:
if indices is not None:
index_range = range(indices[0], indices[1])
logger.info("- Preprocessing: splitting of index range %s", str(indices))
else:
......
......@@ -251,12 +251,12 @@ def compute_scores(algorithm, compute_zt_norm, force = False, indices = None, gr
for group in groups:
# get model ids
model_ids = fs.model_ids(group)
if indices != None:
if indices is not None:
model_ids = model_ids[indices[0]:indices[1]]
logger.info("- Scoring: splitting of index range %s", str(indices))
if compute_zt_norm:
t_model_ids = fs.t_model_ids(group)
if indices != None:
if indices is not None:
t_model_ids = t_model_ids[indices[0]:indices[1]]
# compute A scores
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment