Skip to content

Commit

Permalink
Merge branch 'main' into fix_132
Browse files Browse the repository at this point in the history
  • Loading branch information
gtca authored Oct 16, 2024
2 parents 52f9e1d + c7461aa commit d29c58d
Show file tree
Hide file tree
Showing 13 changed files with 233 additions and 170 deletions.
32 changes: 20 additions & 12 deletions .github/workflows/pythonpackage.yml
Original file line number Diff line number Diff line change
@@ -1,37 +1,45 @@
name: Python package

on: [push]
on:
push:
branches: [main]
pull_request:
branches: [main]
schedule:
- cron: "0 5 1,15 * *"

jobs:
build:

runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: [3.8, 3.9]
python-version: ["3.10", "3.12"]

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v1
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install tools
run: python -m pip install --upgrade pip
- name: Install dependencies
run: >
pip install
".[test]"
git+https://github.com/bioFAM/mofapy2
git+https://github.com/scverse/mudata
- name: List dependencies
run: |
python -m pip install --upgrade pip
python -m pip install umap-learn
python -m pip install .
# python -m pip install mofapy2
python -m pip install git+https://github.com/bioFAM/mofapy2
python -m pip install git+https://github.com/scverse/mudata
pip list
- name: Lint with flake8
run: |
pip install flake8
# stop the build if there are Python syntax errors or undefined names
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Test with pytest
run: |
pip install pytest
pytest
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ __pycache__/
# C extensions
*.so

# cached data
data/

# Distribution / packaging
.Python
build/
Expand Down
11 changes: 6 additions & 5 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
version: 2

build:
os: ubuntu-22.04
tools:
python: "3.12"

# Build from the docs/ directory with Sphinx
sphinx:
configuration: docs/source/conf.py

# Explicitly set the version of Python and its requirements
python:
version: 3.8
install:
- method: pip
path: .
extra_requirements:
- docs
- requirements: docs/requirements.txt
10 changes: 10 additions & 0 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
sphinx==7.2.6
sphinx-rtd-theme==2.0.0
commonmark==0.9.1
recommonmark==0.7.1
sphinx_automodapi==0.17.0
nbsphinx==0.9.3
readthedocs-sphinx-search==0.3.2
sphinx-book-theme==1.1.2
pydata-sphinx-theme==0.15.2
muon
6 changes: 6 additions & 0 deletions docs/source/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@ Release notes

*


v0.1.6
------

* Compatibility with scanpy 1.10

v0.1.5
------

Expand Down
2 changes: 1 addition & 1 deletion muon/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@
from . import atac
from . import prot

__version__ = "0.1.5"
__version__ = "0.1.6"
2 changes: 1 addition & 1 deletion muon/_atac/preproc.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ def tfidf(
if log_tfidf:
tf_idf = np.log1p(tf_idf)

res = np.nan_to_num(tf_idf, 0)
res = np.nan_to_num(tf_idf, nan=0.0)
if not inplace:
return res

Expand Down
Loading

0 comments on commit d29c58d

Please sign in to comment.