Skip to content

Commit

Permalink
Merge pull request #9 from HiDiHlabs/dev
Browse files Browse the repository at this point in the history
Release 1
  • Loading branch information
niklasmueboe authored Jun 19, 2024
2 parents 24bdd8b + 5ae27f5 commit 9d4df9b
Show file tree
Hide file tree
Showing 9 changed files with 289 additions and 190 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/publish-pypi.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: Publish Python Package to PyPI

on:
release:
types: [published]

jobs:
publish:
runs-on: ubuntu-latest
environment: pypi
permissions:
id-token: write # to authenticate as Trusted Publisher to pypi.org
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.x"
cache: "pip"
- run: pip install build
- run: python -m build
- uses: pypa/gh-action-pypi-publish@release/v1
17 changes: 14 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,20 @@

## Installation

`multispaeti` will be made available on [PyPi](https://pypi.org/) and
[conda-forge](https://conda-forge.org/). For detailed installation instructions
please refer to the [documentation](https://multispaeti.readthedocs.io/en/stable/installation.html).
`multispaeti` is available from [PyPI](https://pypi.org/project/multispaeti/)

```bash
pip install multispaeti
```

and [conda-forge](https://anaconda.org/conda-forge/multispaeti)

```bash
conda install conda-forge::multispaeti
```

For detailed installation instructions please refer to the
[documentation](https://multispaeti.readthedocs.io/en/stable/installation.html).

## Documentation

Expand Down
10 changes: 5 additions & 5 deletions docs/source/api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ API
===


The API for :py:class:`multispaeti.MultispatiPCA` tries to follow the design in
`scikit-learn <https://scikit-learn.org/>`_. The plan is to make it fully compatible in
the future by inheriting from :py:class:`sklearn.base.BaseEstimator` and
:py:class:`sklearn.base.TransformerMixin`.

The API for :py:class:`multispaeti.MultispatiPCA` follows the design in
`scikit-learn <https://scikit-learn.org/>`_. It inherits from
:py:class:`sklearn.base.BaseEstimator`, :py:class:`sklearn.base.TransformerMixin`, and
:py:class:`sklearn.base.ClassNamePrefixFeaturesOutMixin` making it fully compatible
with `scikit-learn` pipelines.


.. currentmodule:: multispaeti
Expand Down
25 changes: 10 additions & 15 deletions docs/source/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,34 +2,29 @@ Installation
============


PyPi and ``pip``
PyPI and ``pip``
----------------

``multispaeti`` will soon be available to install from `PyPi <https://pypi.org/>`_.
To install ``multispaeti`` from `PyPI <https://pypi.org/>`_ using ``pip`` just run

.. To install ``multispaeti`` from `PyPi <https://pypi.org/>`_ using ``pip`` just run
.. .. code-block:: bash
.. code-block:: bash
.. pip install multispaeti
pip install multispaeti
conda-forge and ``conda``
-------------------------

``multispaeti`` is not yet available for
`Miniconda <https://docs.conda.io/en/latest/miniconda.html>`_ installations. But we are
planning to add it to `conda-forge <https://conda-forge.org/>`_ soon.
``multispaeti`` can also be installed from `conda-forge <https://conda-forge.org/>`_ via

.. code-block:: bash
.. .. code-block:: bash
.. conda install -c conda-forge multispaeti
conda install conda-forge::multispaeti
.. .. note::
.. note::

.. Of course, it is also possible to use ``mamba`` instead of ``conda``
.. to speed up the installation.
Of course, it is also possible to use ``mamba`` instead of ``conda``
to speed up the installation.


From GitHub
Expand Down
3 changes: 2 additions & 1 deletion docs/source/usage.rst
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,9 @@ As for e.g. :py:class:`sklearn.decomposition.PCA` we first need to
msPCA.fit(X)
X_transformed = msPCA.transform(X)
Alternatively, this can be achieved in one step by
:py:meth:`multispaeti.MultispatiPCA.fit_transform`
:py:meth:`multispaeti.MultispatiPCA.fit_transform` which avoids redundant computation.

.. code-block:: python
Expand Down
Loading

0 comments on commit 9d4df9b

Please sign in to comment.