diff options
-rw-r--r-- | scripts/insert_data.py | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/scripts/insert_data.py b/scripts/insert_data.py index 4dbf27c..63e85ef 100644 --- a/scripts/insert_data.py +++ b/scripts/insert_data.py @@ -169,8 +169,7 @@ def insert_probesets(filepath: str, print() cursor.executemany(probeset_query, probeset_params) probeset_names = probeset_names + tuple( - name[0:name.index("::RAND_")] for name in ( - row["Name"] for row in probeset_params)) + row["Name"] for row in probeset_params) return probeset_names @@ -211,9 +210,8 @@ def insert_means(# pylint: disable=[too-many-locals, too-many-arguments] # which means that we cannot have 2 (or more) ProbeSets which share both # the name and chip_id (platform) at the same time. rand_str = f"::RAND_{random_string()}" - pset_ids = {# pylint: disable=[unnecessary-comprehension] - # Look into simply doing dict(probeset_ids(...)) - name: pset_id + pset_ids = { + name[0:name.index("::RAND_")]: pset_id for name, pset_id in probeset_ids( dbconn, platform_id, |