From 289db0efa1a6e3063e9afc1c52a04f2d020414e1 Mon Sep 17 00:00:00 2001 From: Avani7 Date: Fri, 29 Mar 2024 15:26:29 +0530 Subject: [PATCH] Renamed the tool --- .gitignore | 4 +-- README.md | 32 +++++++++---------- {cmi => crgem}/__init__.py | 0 {cmi => crgem}/common.py | 0 {cmi => crgem}/stages/__init__.py | 0 {cmi => crgem}/stages/create_network.py | 2 +- {cmi => crgem}/stages/functional_analysis.py | 4 +-- {cmi => crgem}/stages/generate_hypothesis.py | 2 +- {cmi => crgem}/stages/grn_inference.py | 2 +- {cmi => crgem}/stages/mechanistic_insights.py | 4 +-- {cmi => crgem}/stages/trrust_analysis.py | 2 +- {cmi => crgem}/tool/PAGA.py | 0 {cmi => crgem}/tool/Signet/SIGNET.R | 0 .../tool/Signet/SIGNET_GRN_prediction.R | 2 +- {cmi => crgem}/tool/Signet/__init__.py | 0 {cmi => crgem}/tool/Signet/tf_list.txt | 0 {cmi => crgem}/tool/__init__.py | 0 {cmi => crgem}/tool/paga_tool.py | 2 +- {cmi => crgem}/tool/signet_tool.py | 2 +- {cmi => crgem}/tool/transsynw_tool.py | 2 +- setup.py | 10 +++--- setup.sh | 4 +-- test_setup.sh | 4 +-- tests/e2e/test_create_network.py | 2 +- .../stages/test_functional_analysis.py | 4 +-- .../stages/test_generate_hypothesis.py | 2 +- tests/unittest/stages/test_grn_inference.py | 2 +- .../stages/test_mechanistic_insights.py | 2 +- tests/unittest/stages/test_trrust_analysis.py | 2 +- 29 files changed, 46 insertions(+), 46 deletions(-) rename {cmi => crgem}/__init__.py (100%) rename {cmi => crgem}/common.py (100%) rename {cmi => crgem}/stages/__init__.py (100%) rename {cmi => crgem}/stages/create_network.py (99%) rename {cmi => crgem}/stages/functional_analysis.py (96%) rename {cmi => crgem}/stages/generate_hypothesis.py (94%) rename {cmi => crgem}/stages/grn_inference.py (91%) rename {cmi => crgem}/stages/mechanistic_insights.py (90%) rename {cmi => crgem}/stages/trrust_analysis.py (99%) rename {cmi => crgem}/tool/PAGA.py (100%) rename {cmi => crgem}/tool/Signet/SIGNET.R (100%) rename {cmi => crgem}/tool/Signet/SIGNET_GRN_prediction.R (97%) rename {cmi => crgem}/tool/Signet/__init__.py (100%) rename {cmi => crgem}/tool/Signet/tf_list.txt (100%) rename {cmi => crgem}/tool/__init__.py (100%) rename {cmi => crgem}/tool/paga_tool.py (60%) rename {cmi => crgem}/tool/signet_tool.py (96%) rename {cmi => crgem}/tool/transsynw_tool.py (96%) diff --git a/.gitignore b/.gitignore index a289a4e..7d93cb0 100644 --- a/.gitignore +++ b/.gitignore @@ -10,8 +10,8 @@ hg19-tss-centered-10kb-10species.mc9nr.feather test_dump code deps -cmi/dependencies -CMI.egg-info +crgem/dependencies +CRGEM.egg-info build/ _build/ __pycache__ diff --git a/README.md b/README.md index 4dd871b..56d1707 100644 --- a/README.md +++ b/README.md @@ -2,10 +2,10 @@ ![workflow badge](https://github.com/thoughtworks/cell-reprogram-workflow/actions/workflows/setup-test-workflow.yml/badge.svg) -### CMI: Cellular conversion using Mechanistic driven Integrated workflow +### CRGEM: Cellular Reprogramming using mechanism-driven Gene Expression Modulation A framework created using already available tools and databases, to perform cellular reprogramming computationally. -To carry out tool specific task using the various tools available separately, the researchers need to go through the tools individually. CMI ease their work by integrating the tools at one place. +To carry out tool specific task using the various tools available separately, the researchers need to go through the tools individually. CRGEM ease their work by integrating the tools at one place. With this integration of the functionalities researchers can invest time in biological inferences and experimentally verifying the key modulators and their effects.
@@ -91,43 +91,43 @@ The starting cell population and terminal cell population cluster IDs to be ener ### Commands - stage: all (TransSynW + PAGA + SIGNET + TRRUST + Cytoscape + Uniprot) - cmi run all --artefacts ./artefacts/[directory_name] --params [start_cell population] [start and terminal_cell population] [annotation file] [terminal cell cluster ID] [startaing cell cluster ID] ./data/terminal.csv ./data/trrust_rawdata_human.tsv + crgem run all --artefacts ./artefacts/[directory_name] --params [start_cell population] [start and terminal_cell population] [annotation file] [terminal cell cluster ID] [startaing cell cluster ID] ./data/terminal.csv ./data/trrust_rawdata_human.tsv - Eg: cmi run all --artefacts ./artefacts/temp --params start.txt start_terminal.txt annotation.txt HPROGFPM HNES ./data/terminal.csv ./data/trrust_rawdata_human.tsv + Eg: crgem run all --artefacts ./artefacts/temp --params start.txt start_terminal.txt annotation.txt HPROGFPM HNES ./data/terminal.csv ./data/trrust_rawdata_human.tsv - stage: generate_hypothesis (TransSynW) - cmi run generate_hypothesis --artefacts ./artefacts/[directory_name] --params [start_cell population] [start and terminal_cell population] [annotation file] [terminal cell cluster ID] + crgem run generate_hypothesis --artefacts ./artefacts/[directory_name] --params [start_cell population] [start and terminal_cell population] [annotation file] [terminal cell cluster ID] - Eg: cmi run generate_hypothesis --artefacts ./artefacts/[directory_name] --params start.txt start_terminal.txt annotation.txt HPROGFPM + Eg: crgem run generate_hypothesis --artefacts ./artefacts/[directory_name] --params start.txt start_terminal.txt annotation.txt HPROGFPM - stage: mechanistic insights (TransSynW + PAGA) - cmi run mechanistic insights --artefacts ./artefacts/[directory_name] --params [start_cell population] [start and terminal_cell population] [annotation file] [terminal cell cluster ID] [startaing cell cluster ID] + crgem run mechanistic insights --artefacts ./artefacts/[directory_name] --params [start_cell population] [start and terminal_cell population] [annotation file] [terminal cell cluster ID] [startaing cell cluster ID] - Eg: cmi run mechanistic_insights --artefacts ./artefacts/temp --params start.txt start_terminal.txt annotation.txt HPROGFPM HNES + Eg: crgem run mechanistic_insights --artefacts ./artefacts/temp --params start.txt start_terminal.txt annotation.txt HPROGFPM HNES - stage: grn inference (SIGNET) - cmi run grn_inference --artefacts ./artefacts/[directory_name] --params ./data/terminal.csv + crgem run grn_inference --artefacts ./artefacts/[directory_name] --params ./data/terminal.csv - Eg: cmi run grn_inference --artefacts ./artefacts/temp --params ./data/terminal.csv + Eg: crgem run grn_inference --artefacts ./artefacts/temp --params ./data/terminal.csv - stage: trrust analysis (TRRUST) - cmi run trrust_analysis --artefacts ./artefacts/[directory_name] --params ./data/trrust_rawdata_human.tsv + crgem run trrust_analysis --artefacts ./artefacts/[directory_name] --params ./data/trrust_rawdata_human.tsv - Eg: cmi run trrust_analysis --artefacts ./artefacts/temp --params ./data/trrust_rawdata_human.tsv + Eg: crgem run trrust_analysis --artefacts ./artefacts/temp --params ./data/trrust_rawdata_human.tsv - stage: gene network (Cytoscape) - cmi run create_network --artefacts ./artefacts/[directory_name] --params ./artefacts/[directory_name]/Trrust_Analysis/trrust_analysis.csv + crgem run create_network --artefacts ./artefacts/[directory_name] --params ./artefacts/[directory_name]/Trrust_Analysis/trrust_analysis.csv - Eg: cmi run create_network --artefacts ./artefacts/temp --params ./artefacts/temp/Trrust_Analysis/trrust_analysis.csv + Eg: crgem run create_network --artefacts ./artefacts/temp --params ./artefacts/temp/Trrust_Analysis/trrust_analysis.csv - stage: functional analysis (Uniprot) - cmi run functional_analysis --artefacts ./artefacts/[directory_name] /Trrust_analysis/transsynw_genes.csv /Trrust_analysis/signet_genes.csv + crgem run functional_analysis --artefacts ./artefacts/[directory_name] /Trrust_analysis/transsynw_genes.csv /Trrust_analysis/signet_genes.csv - Eg: cmi run functional_analysis --artefacts ./artefacts/temp /Trrust_analysis/transsynw_genes.csv /Trrust_analysis/signet_genes.csv + Eg: crgem run functional_analysis --artefacts ./artefacts/temp /Trrust_analysis/transsynw_genes.csv /Trrust_analysis/signet_genes.csv diff --git a/cmi/__init__.py b/crgem/__init__.py similarity index 100% rename from cmi/__init__.py rename to crgem/__init__.py diff --git a/cmi/common.py b/crgem/common.py similarity index 100% rename from cmi/common.py rename to crgem/common.py diff --git a/cmi/stages/__init__.py b/crgem/stages/__init__.py similarity index 100% rename from cmi/stages/__init__.py rename to crgem/stages/__init__.py diff --git a/cmi/stages/create_network.py b/crgem/stages/create_network.py similarity index 99% rename from cmi/stages/create_network.py rename to crgem/stages/create_network.py index e353e81..5478a86 100644 --- a/cmi/stages/create_network.py +++ b/crgem/stages/create_network.py @@ -6,7 +6,7 @@ import json import requests import logging -from cmi.common import clean_up +from crgem.common import clean_up logger = logging.getLogger(__name__) logger.setLevel(logging.DEBUG) diff --git a/cmi/stages/functional_analysis.py b/crgem/stages/functional_analysis.py similarity index 96% rename from cmi/stages/functional_analysis.py rename to crgem/stages/functional_analysis.py index b6a051b..503f23e 100644 --- a/cmi/stages/functional_analysis.py +++ b/crgem/stages/functional_analysis.py @@ -3,8 +3,8 @@ import os import logging import pandas as pd -from cmi.common import clean_up -from cmi.common import http_post, http_request +from crgem.common import clean_up +from crgem.common import http_post, http_request logger = logging.getLogger(__name__) diff --git a/cmi/stages/generate_hypothesis.py b/crgem/stages/generate_hypothesis.py similarity index 94% rename from cmi/stages/generate_hypothesis.py rename to crgem/stages/generate_hypothesis.py index cc2ef40..309c65d 100644 --- a/cmi/stages/generate_hypothesis.py +++ b/crgem/stages/generate_hypothesis.py @@ -1,7 +1,7 @@ "generate_hypothesis.py" -from cmi.tool.transsynw_tool import runTranssynW +from crgem.tool.transsynw_tool import runTranssynW import logging logger = logging.getLogger(__name__) diff --git a/cmi/stages/grn_inference.py b/crgem/stages/grn_inference.py similarity index 91% rename from cmi/stages/grn_inference.py rename to crgem/stages/grn_inference.py index d7ec93d..672cca1 100644 --- a/cmi/stages/grn_inference.py +++ b/crgem/stages/grn_inference.py @@ -1,6 +1,6 @@ "grn_inference.py" -from cmi.tool.signet_tool import runSignetpy, runR +from crgem.tool.signet_tool import runSignetpy, runR import logging logger = logging.getLogger(__name__) diff --git a/cmi/stages/mechanistic_insights.py b/crgem/stages/mechanistic_insights.py similarity index 90% rename from cmi/stages/mechanistic_insights.py rename to crgem/stages/mechanistic_insights.py index 094c20b..7289f80 100644 --- a/cmi/stages/mechanistic_insights.py +++ b/crgem/stages/mechanistic_insights.py @@ -1,8 +1,8 @@ "mechanistic_insights.py" -from cmi.tool.transsynw_tool import runTranssynW -from cmi.tool.paga_tool import runPaga +from crgem.tool.transsynw_tool import runTranssynW +from crgem.tool.paga_tool import runPaga import logging diff --git a/cmi/stages/trrust_analysis.py b/crgem/stages/trrust_analysis.py similarity index 99% rename from cmi/stages/trrust_analysis.py rename to crgem/stages/trrust_analysis.py index 1ed8ef5..c825803 100644 --- a/cmi/stages/trrust_analysis.py +++ b/crgem/stages/trrust_analysis.py @@ -2,7 +2,7 @@ import pandas as pd import numpy as np import os -from cmi.common import clean_up +from crgem.common import clean_up import logging diff --git a/cmi/tool/PAGA.py b/crgem/tool/PAGA.py similarity index 100% rename from cmi/tool/PAGA.py rename to crgem/tool/PAGA.py diff --git a/cmi/tool/Signet/SIGNET.R b/crgem/tool/Signet/SIGNET.R similarity index 100% rename from cmi/tool/Signet/SIGNET.R rename to crgem/tool/Signet/SIGNET.R diff --git a/cmi/tool/Signet/SIGNET_GRN_prediction.R b/crgem/tool/Signet/SIGNET_GRN_prediction.R similarity index 97% rename from cmi/tool/Signet/SIGNET_GRN_prediction.R rename to crgem/tool/Signet/SIGNET_GRN_prediction.R index f75bf7d..975fa8f 100755 --- a/cmi/tool/Signet/SIGNET_GRN_prediction.R +++ b/crgem/tool/Signet/SIGNET_GRN_prediction.R @@ -4,7 +4,7 @@ args= commandArgs(trailingOnly = TRUE) in_path = args[1] library(RcisTarget) -source('./cmi/tool/Signet/SIGNET.R') +source('./crgem/tool/Signet/SIGNET.R') # Select motif database to use (annotations) data("motifAnnotations_hgnc") diff --git a/cmi/tool/Signet/__init__.py b/crgem/tool/Signet/__init__.py similarity index 100% rename from cmi/tool/Signet/__init__.py rename to crgem/tool/Signet/__init__.py diff --git a/cmi/tool/Signet/tf_list.txt b/crgem/tool/Signet/tf_list.txt similarity index 100% rename from cmi/tool/Signet/tf_list.txt rename to crgem/tool/Signet/tf_list.txt diff --git a/cmi/tool/__init__.py b/crgem/tool/__init__.py similarity index 100% rename from cmi/tool/__init__.py rename to crgem/tool/__init__.py diff --git a/cmi/tool/paga_tool.py b/crgem/tool/paga_tool.py similarity index 60% rename from cmi/tool/paga_tool.py rename to crgem/tool/paga_tool.py index e4a9cd1..1d35232 100644 --- a/cmi/tool/paga_tool.py +++ b/crgem/tool/paga_tool.py @@ -1,5 +1,5 @@ "paga_tool.py" -from cmi.tool.PAGA import paga +from crgem.tool.PAGA import paga def runPaga(*args): paga(*args) \ No newline at end of file diff --git a/cmi/tool/signet_tool.py b/crgem/tool/signet_tool.py similarity index 96% rename from cmi/tool/signet_tool.py rename to crgem/tool/signet_tool.py index 2084a4e..7b37a5d 100644 --- a/cmi/tool/signet_tool.py +++ b/crgem/tool/signet_tool.py @@ -3,7 +3,7 @@ import subprocess import os import sys -from cmi.common import clean_up +from crgem.common import clean_up # from dependencies.Signet.SIGNET import signet code_path = './Signet' diff --git a/cmi/tool/transsynw_tool.py b/crgem/tool/transsynw_tool.py similarity index 96% rename from cmi/tool/transsynw_tool.py rename to crgem/tool/transsynw_tool.py index 62c002f..bfbb30e 100644 --- a/cmi/tool/transsynw_tool.py +++ b/crgem/tool/transsynw_tool.py @@ -4,7 +4,7 @@ import subprocess import os import sys -from cmi.common import clean_up +from crgem.common import clean_up cwd = os.getcwd() print("cwd:", cwd) abs_path = os.path.dirname(__file__) diff --git a/setup.py b/setup.py index aa170ad..9cc84e2 100755 --- a/setup.py +++ b/setup.py @@ -2,7 +2,7 @@ from setuptools import setup, find_packages setup_info = dict( - name='CMI', + name='CRGEM', version='0.1', author='E4R', author_email='e4r@thoughtworks.com', @@ -18,16 +18,16 @@ long_description_content_type='text/markdown', license='MIT', # Package info - packages=['cmi'] + ['cmi.' + pkg for pkg in find_packages('cmi')], + packages=['crgem'] + ['crgem.' + pkg for pkg in find_packages('crgem')], package_data={ - "cmi.tool.Signet": ["*.R", "*.txt"], - "cmi.dependencies": ["transsynw/*/*", "SIGNET.py"] + "crgem.tool.Signet": ["*.R", "*.txt"], + "crgem.dependencies": ["transsynw/*/*", "SIGNET.py"] }, # Add _ prefix to the names of temporary build dirs options={'build': {'build_base': '_build'}, }, zip_safe=True, - scripts=['bin/cmi'], + scripts=['bin/crgem'], install_requires=[ 'anndata==0.10.3', 'array-api-compat==1.4', diff --git a/setup.sh b/setup.sh index c2ec94d..b7b183f 100755 --- a/setup.sh +++ b/setup.sh @@ -1,8 +1,8 @@ # TransSynW dependencies -mkdir ./cmi/dependencies -cd ./cmi/dependencies +mkdir ./crgem/dependencies +cd ./crgem/dependencies touch __init__.py git clone --depth=1 https://gitlab.lcsb.uni.lu/CBG/transsynw.git transsynw diff --git a/test_setup.sh b/test_setup.sh index 3bc3fd4..1759e53 100755 --- a/test_setup.sh +++ b/test_setup.sh @@ -8,8 +8,8 @@ python -m pip install --upgrade pip pip install pytest pip install -r requirements.txt -mkdir ./cmi/dependencies -cd ./cmi/dependencies +mkdir ./crgem/dependencies +cd ./crgem/dependencies touch __init__.py git clone --depth=1 https://gitlab.lcsb.uni.lu/CBG/transsynw.git transsynw diff --git a/tests/e2e/test_create_network.py b/tests/e2e/test_create_network.py index 590ad4f..d7e5067 100644 --- a/tests/e2e/test_create_network.py +++ b/tests/e2e/test_create_network.py @@ -4,7 +4,7 @@ import shutil import glob import pandas as pd -from cmi.stages.create_network import create_network #, get_TFs_data, get_targets_data, get_regulators, get_master_regulators +from crgem.stages.create_network import create_network artefacts_path = "./test_dump" diff --git a/tests/unittest/stages/test_functional_analysis.py b/tests/unittest/stages/test_functional_analysis.py index b93bda7..107dc77 100644 --- a/tests/unittest/stages/test_functional_analysis.py +++ b/tests/unittest/stages/test_functional_analysis.py @@ -4,8 +4,8 @@ import shutil import os import filecmp -from cmi.stages.functional_analysis import functional_analysis -from cmi.common import clean_up +from crgem.stages.functional_analysis import functional_analysis +from crgem.common import clean_up transsynw_genes_file = "/Trrust_Analysis/transsynw_genes.csv" signet_genes_file = "/Trrust_Analysis/signet_genes.csv" diff --git a/tests/unittest/stages/test_generate_hypothesis.py b/tests/unittest/stages/test_generate_hypothesis.py index 7688774..fb3a9b8 100644 --- a/tests/unittest/stages/test_generate_hypothesis.py +++ b/tests/unittest/stages/test_generate_hypothesis.py @@ -3,7 +3,7 @@ import filecmp import os import shutil -from cmi.stages.generate_hypothesis import generate_hypothesis +from crgem.stages.generate_hypothesis import generate_hypothesis print(os.getcwd()) args = ["start.txt","start_terminal.txt","annotation.txt","HPROGFPM"] artefacts_path = os.getcwd() + "/" + "./test_dump" diff --git a/tests/unittest/stages/test_grn_inference.py b/tests/unittest/stages/test_grn_inference.py index fa1634e..6044619 100644 --- a/tests/unittest/stages/test_grn_inference.py +++ b/tests/unittest/stages/test_grn_inference.py @@ -4,7 +4,7 @@ import shutil import os import filecmp -from cmi.stages.grn_inference import runR +from crgem.stages.grn_inference import runR # from craft.common import clean_up artefacts_path = "./test_dump" diff --git a/tests/unittest/stages/test_mechanistic_insights.py b/tests/unittest/stages/test_mechanistic_insights.py index bd20641..f9fe633 100644 --- a/tests/unittest/stages/test_mechanistic_insights.py +++ b/tests/unittest/stages/test_mechanistic_insights.py @@ -4,7 +4,7 @@ import os import shutil import glob -from cmi.stages.mechanistic_insights import mechanistic_insights +from crgem.stages.mechanistic_insights import mechanistic_insights args = ["start.txt","start_terminal.txt","annotation.txt","HPROGFPM", "HNES"] artefacts_path = os.getcwd() + "/" + "./test_dump" diff --git a/tests/unittest/stages/test_trrust_analysis.py b/tests/unittest/stages/test_trrust_analysis.py index dafb286..b61c17c 100644 --- a/tests/unittest/stages/test_trrust_analysis.py +++ b/tests/unittest/stages/test_trrust_analysis.py @@ -4,7 +4,7 @@ import shutil import os import filecmp -from cmi.stages.trrust_analysis import trrust_analysis +from crgem.stages.trrust_analysis import trrust_analysis trrust_db_file = "./data/trrust_rawdata_human.tsv" artefacts_path = "./test_dump"