-
Notifications
You must be signed in to change notification settings - Fork 4
Pixeldataset docstrings public #403
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
karlmoresco
wants to merge
10
commits into
dev
Choose a base branch
from
pixeldataset-docstrings-public
base: dev
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
402d885
message
8cbab7c
Initialize Sphinx for docs generation
ee1454f
Configure docs landing page and add dependencies needed
021fa72
Set up resources for generating docs for Python API and CLI
269b71e
Configure options for AutoAPI and review docstrings
6d61952
Do Sphinx/AutoAPI config
d1cf612
Create complementary API overview page
ed92582
Fix docstrings, do AutoAPI config, do styling
b2ebed1
Fix docstring in read in pixeldataset
b36cf02
Fix dummy change
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 @@ | ||
| # Minimal makefile for Sphinx documentation | ||
| # | ||
|
|
||
| # You can set these variables from the command line, and also | ||
| # from the environment for the first two. | ||
| SPHINXOPTS ?= | ||
| SPHINXBUILD ?= sphinx-build | ||
| SOURCEDIR = . | ||
| BUILDDIR = _build | ||
|
|
||
| # Put it first so that "make" without argument is like "make help". | ||
| help: | ||
| @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) | ||
|
|
||
| .PHONY: help Makefile | ||
|
|
||
| # Catch-all target: route all unknown targets to Sphinx using the new | ||
| # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). | ||
| %: Makefile | ||
| @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) |
This file contains hidden or 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,39 @@ | ||
| /* Wider main content column */ | ||
| /* .bd-main .bd-content .bd-article-container { | ||
| max-width: 75em; | ||
| } */ | ||
|
|
||
| /* Optional: allow the whole page layout to grow too */ | ||
| /* .bd-page-width { | ||
| max-width: 100rem; | ||
| } */ | ||
|
|
||
| /* Wrap */ | ||
|
|
||
| .bd-content h1 { | ||
| overflow-wrap: anywhere; | ||
| } | ||
|
|
||
| .prev-next-area a { | ||
| overflow-x: visible; | ||
| } | ||
|
|
||
| .prev-next-area a .prev-next-info { | ||
| min-width: 0; | ||
| } | ||
|
|
||
| .prev-next-area a p.prev-next-title { | ||
| overflow-wrap: anywhere; | ||
| } | ||
|
|
||
| span.pre { | ||
| white-space: normal; | ||
| overflow-wrap: anywhere; | ||
| } | ||
|
|
||
| /* Except */ | ||
|
|
||
| nav.page-toc span.pre { | ||
| white-space: pre; | ||
| overflow-wrap: normal; | ||
| } |
This file contains hidden or 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,16 @@ | ||
| Python API reference | ||
| ==================== | ||
|
|
||
| This section documents the public Python API for Pixelator. | ||
|
|
||
| .. toctree:: | ||
| :maxdepth: 1 | ||
|
|
||
| overview | ||
|
|
||
|
|
||
| .. toctree:: | ||
| :maxdepth: 1 | ||
| :caption: Complete reference: | ||
|
|
||
| generated/pixelator/index |
This file contains hidden or 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 @@ | ||
| API overview | ||
| ============== | ||
|
|
||
| Primary entry points for PNA analysis. | ||
|
|
||
| **Reader** | ||
|
|
||
| * :func:`pixelator.read_pna` | ||
|
|
||
|
|
||
| **Datasets** | ||
|
|
||
| .. * :class:`pixelator.pna.pixeldataset.dataset.PixelDataset` | ||
| * :class:`pixelator.pna.pixeldataset.download.DownloadableDatasets` | ||
|
|
||
| .. **Configuration** | ||
|
|
||
| .. * :class:`pixelator.pna.config.config_instance.pna_config` |
This file contains hidden or 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,8 @@ | ||
| Command-line interface | ||
| ====================== | ||
|
|
||
| This section documents the Pixelator command-line interface. | ||
|
|
||
| .. click:: pixelator.cli.main:main_cli | ||
| :prog: pixelator | ||
| :nested: full |
This file contains hidden or 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,120 @@ | ||
| # Configuration file for the Sphinx documentation builder. | ||
| # | ||
| # For the full list of built-in configuration values, see the documentation: | ||
| # https://www.sphinx-doc.org/en/master/usage/configuration.html | ||
|
|
||
| # -- Project information ----------------------------------------------------- | ||
| # https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information | ||
|
|
||
|
|
||
| project = "Pixelator" | ||
| copyright = "2026 Pixelgen Technologies" | ||
| author = "Pixelgen Technologies" | ||
|
|
||
| # -- General configuration --------------------------------------------------- | ||
| # https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration | ||
|
|
||
| nitpicky = True | ||
| nitpick_ignore = [ | ||
| # --- MPX excluded from AutoAPI --- | ||
| ("py:class", "pixelator.mpx.graph.Graph"), | ||
| # --- No public intersphinx inventory --- | ||
| # (see if these can be resolved without ignoring) | ||
| ("py:class", "duckdb.DuckDBPyConnection"), | ||
| ("py:class", "faiss.IndexBinary"), | ||
| ] | ||
|
|
||
| extensions = [ | ||
| "sphinx.ext.autodoc", | ||
| "sphinx.ext.napoleon", | ||
| "sphinx.ext.intersphinx", | ||
| "sphinx.ext.autosummary", | ||
| "sphinx_design", | ||
| "autoapi.extension", | ||
| "sphinx_click", | ||
| ] | ||
|
|
||
| autoapi_type = "python" | ||
| autoapi_dirs = ["../src/pixelator"] | ||
| autoapi_root = "api/generated" | ||
| autoapi_add_toctree_entry = False | ||
|
|
||
| autoapi_ignore = [ | ||
| "*/pixelator/mpx/*", | ||
| "*/pixelator/mpx/**/*", | ||
| "*/pixelator/cli/*", | ||
| "*/pixelator/cli/**/*", | ||
| "*/pixelator/pna/cli/*", | ||
| "*/pixelator/pna/cli/**/*", | ||
| "*/__pycache__/*", | ||
| "*/__pycache__/**/*", | ||
| ] | ||
|
|
||
| # Options for AutoAPI | ||
| autoapi_options = [ | ||
| "members", # Display children of an object | ||
| "show-inheritance", # Display a list of base classes below the class signature | ||
| "show-module-summary", # Whether to include autosummary directives in generated module documentation. | ||
| "undoc-members", # Display objects that have no docstring | ||
| "imported-members", # For objects imported into a package, display objects imported from the same top level package or module. | ||
| # "special-members", # Display special objects (eg. __foo__ in Python) | ||
| # "inherited-members", # Display children of an object that have been inherited from a base class. | ||
| # Note the absence of the option private-members | ||
| ] | ||
|
|
||
| autoapi_member_order = "alphabetical" | ||
| autoapi_python_class_content = "both" | ||
| autoapi_python_use_implicit_namespaces = True | ||
| autoapi_own_page_level = "class" | ||
| autoapi_own_page_level = "function" | ||
|
|
||
|
|
||
| templates_path = ["_templates"] | ||
| exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] | ||
|
|
||
|
|
||
| # -- Options for HTML output ------------------------------------------------- | ||
| # https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output | ||
|
|
||
| html_theme = "pydata_sphinx_theme" | ||
| html_static_path = ["_static"] | ||
| html_css_files = ["custom.css"] | ||
|
|
||
| autodoc_member_order = "alphabetical" | ||
| autodoc_typehints = "signature" | ||
| autodoc_typehints_format = "short" | ||
| autodoc_typehints_description_target = "documented_params" | ||
|
|
||
| napoleon_google_docstring = True | ||
| napoleon_numpy_docstring = False | ||
|
|
||
| napoleon_include_init_with_doc = True | ||
|
|
||
| napoleon_include_private_with_doc = False | ||
| napoleon_include_special_with_doc = False | ||
|
|
||
| napoleon_use_param = True | ||
| napoleon_use_rtype = True | ||
| napoleon_use_ivar = True | ||
|
|
||
| napoleon_attr_annotations = True | ||
|
|
||
| intersphinx_mapping = { | ||
| "python": ("https://docs.python.org/3", None), | ||
| "numpy": ("https://numpy.org/doc/stable/", None), | ||
| "pandas": ("https://pandas.pydata.org/docs/", None), | ||
| "scipy": ("https://docs.scipy.org/doc/scipy", None), | ||
| "seaborn": ("https://seaborn.pydata.org/", None), | ||
| "polars": ("https://docs.pola.rs/api/python/stable/", None), | ||
| "pydantic": ("https://docs.pydantic.dev/latest/", None), | ||
| "scanpy": ("https://scanpy.readthedocs.io/en/stable/", None), | ||
| "anndata": ("https://anndata.readthedocs.io/en/stable/", None), | ||
| "cutadapt": ("https://cutadapt.readthedocs.io/en/stable/", None), | ||
| "dnaio": ("https://dnaio.readthedocs.io/en/stable/", None), | ||
| "pyarrow": ("https://arrow.apache.org/docs/", None), | ||
| "networkx": ("https://networkx.org/documentation/stable/", None), | ||
| "click": ("https://click.palletsprojects.com/en/stable/", None), | ||
| "packaging": ("https://packaging.pypa.io/en/stable/", None), | ||
| "sklearn": ("https://scikit-learn.org/stable/", None), | ||
| "matplotlib": ("https://matplotlib.org/stable/", None), | ||
| } | ||
This file contains hidden or 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,54 @@ | ||
| Pixelator documentation | ||
| ======================= | ||
|
|
||
| Pixelgen Technologies provides Pixelator, a suite of open source | ||
| software solutions that empower users working with | ||
| `Molecular Pixelation (MPX) <https://software.pixelgen.com/common/glossary/#mpx>`_ | ||
| and `Proximity Network (PNA) <https://software.pixelgen.com/common/glossary/#pna>`_ | ||
| assays in data processing and analysis. | ||
|
|
||
| Pixelator can be used in two ways: as a data processing pipeline | ||
| (nf-core/pixelator) and as a programming library (pixelator). | ||
| The pipeline nf-core/pixelator consists of several steps and will produce | ||
| ready-to-analyze outputs from your initial FASTQ sequencing libraries. | ||
| Usage of Pixelator as a programming library is covered in the API reference and in | ||
| our data analysis sections for MPX and PNA (section for PNA is linked below as "Tutorials"). | ||
|
|
||
|
|
||
| .. grid:: 1 1 2 2 | ||
| :gutter: 2 | ||
|
|
||
| .. grid-item-card:: Python API reference | ||
| :link: api/index | ||
| :link-type: doc | ||
|
|
||
| Browse Python modules, classes, functions, and methods. | ||
|
|
||
| .. grid-item-card:: Command-line interface | ||
| :link: cli/index | ||
| :link-type: doc | ||
|
|
||
| Browse Pixelator command-line interface commands, options, and arguments. | ||
|
|
||
| .. grid-item-card:: Pixelgen software site | ||
| :link: https://software.pixelgen.com/ | ||
| :link-type: url | ||
|
|
||
| See the Pixelgen software site for information about | ||
| software, analysis, and datasets. | ||
|
|
||
| .. .. grid-item-card:: Tutorials | ||
| .. :link: https://software.pixelgen.com/pna-analysis/introduction/ | ||
| .. :link-type: url | ||
|
|
||
| .. See tutorials and code examples for getting started | ||
| .. with Proximity Network Assay (PNA) data analysis | ||
| .. using Pixelator as a Python library. | ||
|
|
||
| .. toctree:: | ||
| :maxdepth: 2 | ||
| :caption: Contents: | ||
| :hidden: | ||
|
|
||
| api/index | ||
| cli/index |
This file contains hidden or 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,35 @@ | ||
| @ECHO OFF | ||
|
|
||
| pushd %~dp0 | ||
|
|
||
| REM Command file for Sphinx documentation | ||
|
|
||
| if "%SPHINXBUILD%" == "" ( | ||
| set SPHINXBUILD=sphinx-build | ||
| ) | ||
| set SOURCEDIR=. | ||
| set BUILDDIR=_build | ||
|
|
||
| %SPHINXBUILD% >NUL 2>NUL | ||
| if errorlevel 9009 ( | ||
| echo. | ||
| echo.The 'sphinx-build' command was not found. Make sure you have Sphinx | ||
| echo.installed, then set the SPHINXBUILD environment variable to point | ||
| echo.to the full path of the 'sphinx-build' executable. Alternatively you | ||
| echo.may add the Sphinx directory to PATH. | ||
| echo. | ||
| echo.If you don't have Sphinx installed, grab it from | ||
| echo.https://www.sphinx-doc.org/ | ||
| exit /b 1 | ||
| ) | ||
|
|
||
| if "%1" == "" goto help | ||
|
|
||
| %SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% | ||
| goto end | ||
|
|
||
| :help | ||
| %SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% | ||
|
|
||
| :end | ||
| popd |
This file contains hidden or 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
This file contains hidden or 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
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.