rectanglepy 0.4.7__tar.gz → 0.5.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (58) hide show
  1. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/.bumpversion.cfg +1 -1
  2. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/PKG-INFO +17 -11
  3. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/README.md +9 -6
  4. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/docs/Makefile +3 -0
  5. rectanglepy-0.5.1/docs/_static/rec_logo.001.png +0 -0
  6. rectanglepy-0.5.1/docs/api.md +15 -0
  7. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/docs/conf.py +20 -14
  8. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/docs/contributing.md +0 -74
  9. rectanglepy-0.5.1/docs/notebooks/example.ipynb +551 -0
  10. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/pyproject.toml +7 -4
  11. rectanglepy-0.5.1/src/rectanglepy/__init__.py +8 -0
  12. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/src/rectanglepy/pp/create_signature.py +3 -25
  13. rectanglepy-0.5.1/src/rectanglepy/rectangle.py +112 -0
  14. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/tests/test_pp.py +0 -34
  15. rectanglepy-0.4.7/docs/api.md +0 -17
  16. rectanglepy-0.4.7/docs/notebooks/example.ipynb +0 -352
  17. rectanglepy-0.4.7/src/rectanglepy/__init__.py +0 -8
  18. rectanglepy-0.4.7/src/rectanglepy/rectangle.py +0 -222
  19. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/.cruft.json +0 -0
  20. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/.editorconfig +0 -0
  21. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/.github/ISSUE_TEMPLATE/bug_report.yml +0 -0
  22. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/.github/ISSUE_TEMPLATE/config.yml +0 -0
  23. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/.github/ISSUE_TEMPLATE/feature_request.yml +0 -0
  24. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/.github/PULL_REQUEST_TEMPLATE.md +0 -0
  25. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/.github/workflows/build.yaml +0 -0
  26. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/.github/workflows/release.yaml +0 -0
  27. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/.github/workflows/release_testpypi.yaml +0 -0
  28. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/.github/workflows/test.yaml +0 -0
  29. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/.gitignore +0 -0
  30. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/.pre-commit-config.yaml +0 -0
  31. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/.readthedocs.yaml +0 -0
  32. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/CHANGELOG.md +0 -0
  33. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/LICENSE +0 -0
  34. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/docs/_static/.gitkeep +0 -0
  35. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/docs/_templates/.gitkeep +0 -0
  36. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/docs/_templates/autosummary/class.rst +0 -0
  37. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/docs/changelog.md +0 -0
  38. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/docs/extensions/typed_returns.py +0 -0
  39. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/docs/index.md +0 -0
  40. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/docs/make.bat +0 -0
  41. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/docs/references.bib +0 -0
  42. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/docs/references.md +0 -0
  43. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/src/rectanglepy/data/hao1_annotations_small.zip +0 -0
  44. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/src/rectanglepy/data/hao1_counts_small.zip +0 -0
  45. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/src/rectanglepy/data/small_fino_bulks.zip +0 -0
  46. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/src/rectanglepy/pp/__init__.py +0 -0
  47. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/src/rectanglepy/pp/rectangle_signature.py +0 -0
  48. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/src/rectanglepy/tl/__init__.py +0 -0
  49. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/src/rectanglepy/tl/deconvolution.py +0 -0
  50. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/tests/data/TIL10_signature.txt +0 -0
  51. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/tests/data/bulk_small.csv +0 -0
  52. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/tests/data/cell_annotations_small.txt +0 -0
  53. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/tests/data/quanTIseq_SimRNAseq_mixture_smaller.csv +0 -0
  54. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/tests/data/quanTIseq_SimRNAseq_read_fractions_small.txt +0 -0
  55. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/tests/data/sc_object_small.csv +0 -0
  56. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/tests/data/signature_hao1.csv +0 -0
  57. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/tests/test_rectangle.py +0 -0
  58. {rectanglepy-0.4.7 → rectanglepy-0.5.1}/tests/test_tl.py +0 -0
@@ -1,5 +1,5 @@
1
1
  [bumpversion]
2
- current_version = 0.4.7
2
+ current_version = 0.5.1
3
3
  tag = True
4
4
  commit = True
5
5
 
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.3
1
+ Metadata-Version: 2.4
2
2
  Name: rectanglepy
3
- Version: 0.4.7
3
+ Version: 0.5.1
4
4
  Summary: Hierarchical deconvolution of bulk transcriptomics
5
5
  Project-URL: Documentation, https://rectanglepy.readthedocs.io/
6
6
  Project-URL: Source, https://github.com/ComputationalBiomedicineGroup/Rectangle
@@ -28,26 +28,29 @@ License: MIT License
28
28
  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
29
29
  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30
30
  SOFTWARE.
31
+ License-File: LICENSE
31
32
  Requires-Python: >=3.10
32
33
  Requires-Dist: anndata<0.10.9,>=0.8.0
33
34
  Requires-Dist: loguru
34
35
  Requires-Dist: numpy<2.0.0,>=1.0.0
35
36
  Requires-Dist: pydeseq2==0.4.11
36
37
  Requires-Dist: quadprog==0.1.12
38
+ Requires-Dist: scipy==1.13.0
37
39
  Requires-Dist: statsmodels>=0.14.1
38
40
  Provides-Extra: dev
39
41
  Requires-Dist: bump2version; extra == 'dev'
40
42
  Requires-Dist: pre-commit; extra == 'dev'
41
43
  Requires-Dist: twine>=4.0.2; extra == 'dev'
42
44
  Provides-Extra: doc
45
+ Requires-Dist: furo; extra == 'doc'
43
46
  Requires-Dist: ipykernel; extra == 'doc'
44
47
  Requires-Dist: ipython; extra == 'doc'
45
48
  Requires-Dist: myst-nb; extra == 'doc'
49
+ Requires-Dist: sphinx; extra == 'doc'
46
50
  Requires-Dist: sphinx-autodoc-typehints; extra == 'doc'
47
- Requires-Dist: sphinx-book-theme>=1.0.0; extra == 'doc'
51
+ Requires-Dist: sphinx-book-theme; extra == 'doc'
48
52
  Requires-Dist: sphinx-copybutton; extra == 'doc'
49
- Requires-Dist: sphinx>=4; extra == 'doc'
50
- Requires-Dist: sphinxcontrib-bibtex>=1.0.0; extra == 'doc'
53
+ Requires-Dist: sphinxcontrib-bibtex; extra == 'doc'
51
54
  Provides-Extra: test
52
55
  Requires-Dist: pytest; extra == 'test'
53
56
  Description-Content-Type: text/markdown
@@ -61,10 +64,13 @@ Description-Content-Type: text/markdown
61
64
  [link-tests]: https://github.com/ComputationalBiomedicineGroup/Rectangle/actions/workflows/build.yaml
62
65
  [badge-docs]: https://img.shields.io/readthedocs/rectanglepy
63
66
 
64
- Rectangle embodies a ”second-generation” deconvolution methodology, setting itself apart from other second-generation
65
- methods through its efficiency in signature creation and its handling of challenges within the deconvolution process.
66
- To establish a precise deconvolution method, we employ a hierarchical analysis approach, incorporate mRNA bias
67
- correction, and provide an estimation of unknown cellular content.
67
+ Rectangle is an open-source Python package developed for computational deconvolution.
68
+
69
+ Rectangle presents a novel approach to second-generation deconvolution, characterized by hierarchical processing,
70
+ an estimation of unknown cellular content and a significant reduction in data volume during signature matrix computation.
71
+
72
+ Rectangle was developed to outperform existing deconvolution solutions by introducing methods that promise
73
+ improvements in cell-type fraction estimation accuracy while keeping a low computational profile.
68
74
 
69
75
  ## Getting started
70
76
 
@@ -74,12 +80,12 @@ Please refer to the [documentation][link-docs]. In particular, the
74
80
 
75
81
  ## Installation
76
82
 
77
- You need to have Python 3.10 or newer installed on your system. If you don't have
83
+ You need to have Python 3.10 or higher installed on your system. If you don't have
78
84
  Python installed, we recommend installing [Mambaforge](https://github.com/conda-forge/miniforge#mambaforge).
79
85
 
80
86
  How to install Rectangle:
81
87
 
82
- Install the latest release of `Rectangle` from `PyPI <https://pypi.org/project/rectanglepy/>`:
88
+ Install the latest release of `Rectangle` from `PyPI` <https://pypi.org/project/rectanglepy/>:
83
89
 
84
90
  ```bash
85
91
  pip install rectanglepy
@@ -7,10 +7,13 @@
7
7
  [link-tests]: https://github.com/ComputationalBiomedicineGroup/Rectangle/actions/workflows/build.yaml
8
8
  [badge-docs]: https://img.shields.io/readthedocs/rectanglepy
9
9
 
10
- Rectangle embodies a ”second-generation” deconvolution methodology, setting itself apart from other second-generation
11
- methods through its efficiency in signature creation and its handling of challenges within the deconvolution process.
12
- To establish a precise deconvolution method, we employ a hierarchical analysis approach, incorporate mRNA bias
13
- correction, and provide an estimation of unknown cellular content.
10
+ Rectangle is an open-source Python package developed for computational deconvolution.
11
+
12
+ Rectangle presents a novel approach to second-generation deconvolution, characterized by hierarchical processing,
13
+ an estimation of unknown cellular content and a significant reduction in data volume during signature matrix computation.
14
+
15
+ Rectangle was developed to outperform existing deconvolution solutions by introducing methods that promise
16
+ improvements in cell-type fraction estimation accuracy while keeping a low computational profile.
14
17
 
15
18
  ## Getting started
16
19
 
@@ -20,12 +23,12 @@ Please refer to the [documentation][link-docs]. In particular, the
20
23
 
21
24
  ## Installation
22
25
 
23
- You need to have Python 3.10 or newer installed on your system. If you don't have
26
+ You need to have Python 3.10 or higher installed on your system. If you don't have
24
27
  Python installed, we recommend installing [Mambaforge](https://github.com/conda-forge/miniforge#mambaforge).
25
28
 
26
29
  How to install Rectangle:
27
30
 
28
- Install the latest release of `Rectangle` from `PyPI <https://pypi.org/project/rectanglepy/>`:
31
+ Install the latest release of `Rectangle` from `PyPI` <https://pypi.org/project/rectanglepy/>:
29
32
 
30
33
  ```bash
31
34
  pip install rectanglepy
@@ -18,3 +18,6 @@ help:
18
18
  # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
19
19
  %: Makefile
20
20
  @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
21
+
22
+ html:
23
+ @$(SPHINXBUILD) -b html "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
@@ -0,0 +1,15 @@
1
+ # API
2
+
3
+ ## Rectangle
4
+
5
+ ```{eval-rst}
6
+ .. currentmodule:: rectanglepy
7
+
8
+ .. autosummary::
9
+ :toctree: generated
10
+
11
+ rectangle
12
+ pp.build_rectangle_signatures
13
+ tl.deconvolution
14
+ pp.RectangleSignatureResult
15
+ ```
@@ -37,6 +37,8 @@ html_context = {
37
37
  "github_repo": "Rectangle", # Repo name
38
38
  "github_version": "main", # Version
39
39
  "conf_py_path": "/docs/", # Path in the checkout to the docs root
40
+ "repository_url": repository_url,
41
+ "use_repository_button": True,
40
42
  }
41
43
 
42
44
  # -- General configuration ---------------------------------------------------
@@ -103,27 +105,31 @@ exclude_patterns = ["_build", "Thumbs.db", ".DS_Store", "**.ipynb_checkpoints"]
103
105
 
104
106
  # The theme to use for HTML and HTML Help pages. See the documentation for
105
107
  # a list of builtin themes.
106
- #
107
- html_theme = "sphinx_book_theme"
108
+
109
+ html_theme = "furo"
108
110
  html_static_path = ["_static"]
109
111
  html_title = "rectangle"
110
112
 
113
+
114
+ html_logo = "_static/rec_logo.001.png"
115
+
111
116
  html_theme_options = {
112
- "repository_url": repository_url,
113
- "use_repository_button": True,
114
117
  "path_to_docs": "docs/",
118
+ "sidebar_hide_name": True, # Hide the project name in the sidebar
119
+ "footer_icons": [
120
+ {
121
+ "name": "GitHub",
122
+ "url": repository_url,
123
+ "html": """
124
+ <svg stroke="currentColor" fill="currentColor" stroke-width="0" viewBox="0 0 16 16">
125
+ <path fill-rule="evenodd" d="M8 0C3.58 0 0 3.58 0 8c0 3.54 2.29 6.53 5.47 7.59.4.07.55-.17.55-.38 0-.19-.01-.82-.01-1.49-2.01.37-2.53-.49-2.69-.94-.09-.23-.48-.94-.82-1.13-.28-.15-.68-.52-.01-.53.63-.01 1.08.58 1.23.82.72 1.21 1.87.87 2.33.66.07-.52.28-.87.51-1.07-1.78-.2-3.64-.89-3.64-3.95 0-.87.31-1.59.82-2.15-.08-.2-.36-1.02.08-2.12 0 0 .67-.21 2.2.82.64-.18 1.32-.27 2-.27.68 0 1.36.09 2 .27 1.53-1.04 2.2-.82 2.2-.82.44 1.1.16 1.92.08 2.12.51.56.82 1.27.82 2.15 0 3.07-1.87 3.75-3.65 3.95.29.25.54.73.54 1.48 0 1.07-.01 1.93-.01 2.2 0 .21.15.46.55.38A8.013 8.013 0 0 0 16 8c0-4.42-3.58-8-8-8z"></path>
126
+ </svg>
127
+ """,
128
+ "class": "",
129
+ },
130
+ ],
115
131
  }
116
132
 
117
- pygments_style = "emacs"
118
-
119
- nitpick_ignore = [
120
- # If building the documentation fails because of a missing link that is outside your control,
121
- # you can add an exception to this list.
122
- # ("py:class", "igraph.Graph"),
123
- ]
124
-
125
- print("Pygments style:", pygments_style)
126
-
127
133
 
128
134
  def setup(app):
129
135
  """App setup hook."""
@@ -7,48 +7,6 @@ information to get you started on contributing.
7
7
  We assume that you are already familiar with git and with making pull requests on GitHub. If not, please refer
8
8
  to the [scanpy developer guide][].
9
9
 
10
- ## Installing dev dependencies
11
-
12
- In addition to the packages needed to _use_ this package, you need additional python packages to _run tests_ and _build
13
- the documentation_. It's easy to install them using `pip`:
14
-
15
- ```bash
16
- cd Rectangle
17
- pip install -e ".[dev,test,doc]"
18
- ```
19
-
20
- ## Code-style
21
-
22
- This template uses [pre-commit][] to enforce consistent code-styles. On every commit, pre-commit checks will either
23
- automatically fix issues with the code, or raise an error message. See [pre-commit checks](template_usage.md#pre-commit-checks) for
24
- a full list of checks enabled for this repository.
25
-
26
- To enable pre-commit locally, simply run
27
-
28
- ```bash
29
- pre-commit install
30
- ```
31
-
32
- in the root of the repository. Pre-commit will automatically download all dependencies when it is run for the first time.
33
-
34
- Alternatively, you can rely on the [pre-commit.ci][] service enabled on GitHub. If you didn't run `pre-commit` before
35
- pushing changes to GitHub it will automatically commit fixes to your pull request, or show an error message.
36
-
37
- If pre-commit.ci added a commit on a branch you still have been working on locally, simply use
38
-
39
- ```bash
40
- git pull --rebase
41
- ```
42
-
43
- to integrate the changes into yours.
44
- While the [pre-commit.ci][] is useful, we strongly encourage installing and running pre-commit locally first to understand its usage.
45
-
46
- Finally, most editors have an _autoformat on save_ feature. Consider enabling this option for [black][black-editors]
47
- and [prettier][prettier-editors].
48
-
49
- [black-editors]: https://black.readthedocs.io/en/stable/integrations/editors.html
50
- [prettier-editors]: https://prettier.io/docs/en/editors.html
51
-
52
10
  ## Writing tests
53
11
 
54
12
  ```{note}
@@ -102,38 +60,6 @@ to publish the created tag on GitHub.
102
60
 
103
61
  [bump2version]: https://github.com/c4urself/bump2version
104
62
 
105
- ### Building and publishing the package on PyPI
106
-
107
- Python packages are not distributed as source code, but as _distributions_. The most common distribution format is the so-called _wheel_. To build a _wheel_, run
108
-
109
- ```bash
110
- python -m build
111
- ```
112
-
113
- This command creates a _source archive_ and a _wheel_, which are required for publishing your package to [PyPI][]. These files are created directly in the root of the repository.
114
-
115
- Before uploading them to [PyPI][] you can check that your _distribution_ is valid by running:
116
-
117
- ```bash
118
- twine check dist/*
119
- ```
120
-
121
- and finally publishing it with:
122
-
123
- ```bash
124
- twine upload dist/*
125
- ```
126
-
127
- Provide your username and password when requested and then go check out your package on [PyPI][]!
128
-
129
- For more information, follow the [Python packaging tutorial][].
130
-
131
- It is possible to automate this with GitHub actions, see also [this feature request][pypi-feature-request]
132
- in the cookiecutter-scverse template.
133
-
134
- [python packaging tutorial]: https://packaging.python.org/en/latest/tutorials/packaging-projects/#generating-distribution-archives
135
- [pypi-feature-request]: https://github.com/scverse/cookiecutter-scverse/issues/88
136
-
137
63
  ## Writing documentation
138
64
 
139
65
  Please write documentation for new or changed features and use-cases. This project uses [sphinx][] with the following features: