-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
7646650
commit 38c7dff
Showing
151 changed files
with
66,059 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
.ipynb* | ||
.idea/* | ||
static/* | ||
tests/* | ||
data/tcga | ||
data/tcga.clinical.pkl | ||
data/tcga.genomic.pkl | ||
data/genes.csv | ||
data/genes.oncopanel.csv | ||
data/Final_gene_map_oncopanel.v1.txt | ||
dev_data/* | ||
elasticsearch/es_data/* | ||
dump/* | ||
*Dockerfile* | ||
.dockerignore | ||
**/.git | ||
**/.gitignore | ||
**/.gitattributes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
*.pkl filter=lfs diff=lfs merge=lfs -text |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,80 @@ | ||
# ignore certs | ||
saml | ||
apache-* | ||
|
||
# ignore pycharm | ||
.idea/ | ||
|
||
# ignore vscode | ||
.vscode/ | ||
|
||
# Byte-compiled / optimized / DLL files | ||
__pycache__/ | ||
*.py[cod] | ||
|
||
# C extensions | ||
*.so | ||
|
||
# Distribution / packaging | ||
.Python | ||
env/ | ||
build/ | ||
develop-eggs/ | ||
dist/ | ||
downloads/ | ||
eggs/ | ||
.eggs/ | ||
lib/ | ||
lib64/ | ||
parts/ | ||
sdist/ | ||
var/ | ||
*.egg-info/ | ||
.installed.cfg | ||
*.egg | ||
|
||
# PyInstaller | ||
# Usually these files are written by a python script from a template | ||
# before PyInstaller builds the exe, so as to inject date/other infos into it. | ||
*.manifest | ||
*.spec | ||
|
||
# Installer logs | ||
pip-log.txt | ||
pip-delete-this-directory.txt | ||
|
||
# Unit test / coverage reports | ||
htmlcov/ | ||
.tox/ | ||
.coverage | ||
.coverage.* | ||
.cache | ||
nosetests.xml | ||
coverage.xml | ||
*,cover | ||
|
||
# Translations | ||
*.mo | ||
*.pot | ||
|
||
# Django stuff: | ||
*.log | ||
|
||
# Sphinx documentation | ||
docs/_build/ | ||
|
||
# PyBuilder | ||
target/ | ||
|
||
# osx | ||
.DS_Store | ||
|
||
elasticsearch/es_data/* | ||
dump/* | ||
|
||
src/* | ||
python-xmlsec/* | ||
|
||
# mypy | ||
.mypy_cache | ||
dev_data/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
default: | ||
image: python:3.7 | ||
|
||
variables: | ||
MONGO_HOST: "localhost" | ||
MONGO_PORT: 27017 | ||
MONGO_USERNAME: "" | ||
MONGO_PASSWORD: "" | ||
MONGO_DBNAME: matchminer_test | ||
MONGO_URI: mongodb://localhost:27017/matchminer_test | ||
ONCOTREE_CUSTOM_DIR: /builds/matchminer/matchminerAPI/data/oncotree_file.txt | ||
EMAIL_CONFIG: /builds/matchminer/matchminerAPI/email.config.json | ||
SECRETS_JSON: /builds/matchminer/matchminerAPI/SECRETS_JSON.json | ||
|
||
before_script: | ||
# install mongo | ||
- apt-get update && apt install -y dirmngr gnupg apt-transport-https software-properties-common ca-certificates curl | ||
- wget -qO - https://www.mongodb.org/static/pgp/server-4.2.asc | apt-key add - | ||
- add-apt-repository 'deb https://repo.mongodb.org/apt/debian buster/mongodb-org/4.2 main' | ||
- apt-get update | ||
- apt-get install -y mongodb-org libxml2-dev libxslt1-dev libxmlsec1-dev | ||
- DEBIAN_FRONTEND=noninteractive apt-get update --fix-missing && apt-get update | ||
- mkdir -p /data/db && touch mongod.log | ||
- mongod --logpath /builds/matchminer/matchminerAPI/mongod.log --quiet & | ||
|
||
# load test data | ||
- mongorestore -d matchminer_test --dir=tests/data | ||
- pip install -r requirements.txt | ||
|
||
# set secrets file and run tests | ||
- echo "{\"MONGO_HOST\":\"$MONGO_HOST\",\"MONGO_PORT\":\"$MONGO_PORT\",\"MONGO_USERNAME\":\"$MONGO_USERNAME\",\"MONGO_PASSWORD\":\"$MONGO_PASSWORD\",\"MONGO_DBNAME\":\"$MONGO_DBNAME\",\"MONGO_URI\":\"$MONGO_URI\"}" > SECRETS_JSON.json | ||
|
||
run_test: | ||
script: | ||
- nosetests -v tests/unit | ||
- nosetests -v --with-xunit --with-coverage tests | ||
|
||
|
||
artifacts: | ||
reports: | ||
junit: nosetests.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
FROM python:3.8-slim | ||
|
||
# Install packages needed to compile dependencies: | ||
RUN DEBIAN_FRONTEND=noninteractive apt-get update --fix-missing && apt-get install -y \ | ||
libxml2-dev \ | ||
libxslt1-dev \ | ||
libxmlsec1-dev \ | ||
libxmlsec1-openssl \ | ||
pkg-config \ | ||
git \ | ||
gcc | ||
|
||
# Configure pip | ||
# Counterintuitively, PIP_NO_COMPILE=no is needed to turn compiling *off* | ||
# We do this partly because compiling is not reproducible, creating pointless diffs in images, | ||
# and partly to reduce image size. | ||
ENV PIP_NO_CACHE_DIR=1 PIP_NO_COMPILE=no | ||
RUN mkdir /matchminerAPI | ||
|
||
# Install requirements: | ||
COPY ./requirements.txt /matchminerAPI/requirements.txt | ||
WORKDIR /matchminerAPI | ||
RUN pip install -r requirements.txt | ||
|
||
# Hack to work around https://github.com/py-bson/bson/issues/82 | ||
RUN pip --no-input uninstall --yes bson | ||
RUN pip --no-input uninstall --yes pymongo | ||
RUN pip install 'pymongo==3.10' | ||
|
||
ENV ONCOTREE_CUSTOM_DIR /matchminerAPI/data/oncotree_file.txt | ||
|
||
# Use an (anonymous) volume to hold "*.pyc" files: | ||
VOLUME /bytecode | ||
RUN mkdir -p /bytecode | ||
ENV PYTHONPYCACHEPREFIX=/bytecode | ||
|
||
# Expose and bind to port 80: | ||
EXPOSE 80 | ||
CMD gunicorn wsgi:app --bind=0.0.0.0:80 | ||
|
||
# Copy over source files: | ||
COPY . /matchminerAPI/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
FROM python:3.7 | ||
|
||
# install ubuntu packages. | ||
RUN DEBIAN_FRONTEND=noninteractive apt-get update --fix-missing && apt-get install -y \ | ||
libxml2-dev \ | ||
libxslt1-dev \ | ||
libxmlsec1-dev \ | ||
&& apt-get clean \ | ||
&& apt-get autoremove | ||
|
||
RUN mkdir /matchminerAPI | ||
COPY ./requirements.txt /matchminerAPI/requirements.txt | ||
WORKDIR /matchminerAPI | ||
|
||
RUN pip install -r requirements.txt | ||
|
||
# Hack to work around https://github.com/py-bson/bson/issues/82 | ||
RUN pip --no-input uninstall --yes bson | ||
RUN pip --no-input uninstall --yes pymongo | ||
RUN pip install 'pymongo==3.10' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# MatchMiner API | ||
Welcome to the documentation for the MatchMiner API! MatchMiner is a system designed to match cancer patients to genomically driven clinical trials using Clinical Trial Markup Language (CTML) and patient clinical and genomic data. | ||
|
||
The MatchMiner platform can be used on local instances that provide access to private data. If you are interested in the development of new features, or in setting up a local instance of the MatchMiner system, please see the documentation, or contact [[email protected]](https://app.gitbook.com/@matchminer/s/matchminer) | ||
|
||
# [Documentation](https://matchminer.gitbook.io/) | ||
[Data Model](https://matchminer.gitbook.io/matchminer/matchminer-api/data-model) | ||
|
||
[Developer Setup](https://matchminer.gitbook.io/matchminer/matchminer-api/development-setup) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
""" | ||
Extensible validation for Python dictionaries. | ||
:copyright: 2012-2016 by Nicola Iarocci. | ||
:license: ISC, see LICENSE for more details. | ||
Full documentation is available at http://python-cerberus.org/ | ||
""" | ||
|
||
from .cerberus import Validator, DocumentError | ||
from .schema import rules_set_registry, schema_registry, Registry, SchemaError | ||
|
||
|
||
__version__ = "1.0rc" | ||
|
||
__all__ = [ | ||
DocumentError.__name__, | ||
Registry.__name__, | ||
SchemaError.__name__, | ||
Validator.__name__, | ||
'schema_registry', | ||
'rules_set_registry' | ||
] |
Oops, something went wrong.