diff --git a/.github/workflows/deploy.yaml b/.github/workflows/deploy.yaml new file mode 100644 index 0000000..55dfd74 --- /dev/null +++ b/.github/workflows/deploy.yaml @@ -0,0 +1,26 @@ +name: Deploy to GitHub Pages + +permissions: + contents: write + +on: + push: + branches: [ "main", "master" ] + workflow_dispatch: + +jobs: + deploy: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.11" + + - name: Install MkDocs + run: pip install mkdocs-material + + - name: Deploy to GitHub Pages + run: mkdocs gh-deploy --force diff --git a/.github/workflows/test_installation.yaml b/.github/workflows/test_installation.yaml new file mode 100644 index 0000000..3c92499 --- /dev/null +++ b/.github/workflows/test_installation.yaml @@ -0,0 +1,37 @@ +name: Tests + +on: + push: + branches: [main] + pull_request: + branches: [main, "release/*"] + +jobs: + run_tests: + runs-on: ${{ matrix.os }} + + strategy: + fail-fast: false + matrix: + os: ["ubuntu-latest", "macos-latest", "windows-latest"] + python-version: ["3.9", "3.10","3.11","3.12","3.13"] + + timeout-minutes: 20 + + steps: + - name: Checkout + uses: actions/checkout@v3 + + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v4 + with: + python-version: ${{ matrix.python-version }} + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install -e . + + - name: List dependencies + run: | + python -m pip list diff --git a/LICENSE.md b/LICENSE.md new file mode 100644 index 0000000..9d73739 --- /dev/null +++ b/LICENSE.md @@ -0,0 +1,6 @@ +Non-Commercial License +Yale Copyright © 2024 Yale University. + +Permission is hereby granted to use, copy, modify, and distribute this Software for any non-commercial purpose. Any distribution or modification or derivations of the Software (together “Derivative Works”) must be made available on GitHub and shall include this copyright notice and this permission notice in all copies or substantial portions of the Software. For the purposes of this license, "non-commercial" means not intended for or directed towards commercial advantage or monetary compensation either via the Software itself or Derivative Works or uses of either which lead to or generate any commercial products. In any event, the use and modification of the Software or Derivative Works shall remain governed by the terms and conditions of this Agreement; Any commercial use of the Software requires a separate commercial license from the copyright holder at Yale University. Direct any requests for commercial licenses to Yale Ventures at yaleventures@yale.edu. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \ No newline at end of file diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..3c3b44e --- /dev/null +++ b/Makefile @@ -0,0 +1,12 @@ +.ONESHELL: +SHELL := /bin/bash +SRC = $(wildcard ./*.ipynb) + +pypi: dist + twine upload --repository pypi dist/* + +dist: clean + python -m build + +clean: + rm -rf dist \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index 6b55ed7..dbf48bf 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,10 +1,24 @@ [project] name = "ritini" -version = "0.1.0" -description = "Add your description here" +version = "0.0.1" +description = "RiTINI is a Python package for modeling and analyzing gene regulatory networks from single cell trajectories." readme = "README.md" +requires-python = ">=3.9" +# license = "LicenseRef-Yale-License" +license-files =["LICENSE.md"] +keywords = ["neural ode", "trajectory", "ritini", "gene regulatory", "single cell RNA", "graphs"] +authors = [ + {name = "bjoaofelipe", email = "joaofelipe.rocha@yale.edu"}, + {name = "siddharthviswanath", email = "siddharth.viswanath@yale.edu"} +] -requires-python = ">=3.10" +classifiers = [ + "Development Status :: 2 - Pre-Alpha", + "Intended Audience :: Developers", + # "License :: Yale License", + "Programming Language :: Python :: 3", + "Programming Language :: Python :: 3 :: Only", +] dependencies = [ "matplotlib>=3.10.6", @@ -17,12 +31,20 @@ dependencies = [ "networkx>=3.0", "numpy>=1.24.0", "torchdiffeq>=0.2.3", - "pytest>=8.4.2", "scanpy>=1.11.4", "scikit-misc>=0.5.1", - "ipykernel>=6.30.1", "pyyaml>=6.0.2", ] [tool.setuptools.packages.find] include = ["ritini", "ritini.*"] + +[build-system] +requires = ["setuptools>=61.0", "wheel"] +build-backend = "setuptools.build_meta" + +[dependency-groups] +dev = [ + "ipykernel>=6.29.5", + "pytest>=8.4.2", +] diff --git a/ritini/__init__.py b/ritini/__init__.py index e69de29..ee31960 100644 --- a/ritini/__init__.py +++ b/ritini/__init__.py @@ -0,0 +1,6 @@ +from ritini.models.RiTINI import RiTINI +from ritini.utils.utils import load_config, get_activation, get_device +from ritini.data.trajectory_loader import prepare_trajectories_data +from ritini.data.temporal_graph import TemporalGraphDataset +from ritini.train import train_epoch +from ritini.utils.preprocess import process_trajectory_data \ No newline at end of file