Skip to content

Commit

Permalink
Merge branch 'main' into pre-comp-signature-passing
Browse files Browse the repository at this point in the history
  • Loading branch information
rchan26 committed Oct 12, 2023
2 parents 1d2ad4c + 53a1a5e commit a24bfbf
Show file tree
Hide file tree
Showing 8 changed files with 98 additions and 42 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,6 @@ jobs:
- uses: pypa/gh-action-pypi-publish@release/v1
if: github.event_name == 'release' && github.event.action == 'published'
with:
# Remember to tell (test-)pypi about this repo before publishing
# Remove this line to publish to PyPI
repository-url: https://test.pypi.org/legacy/
# Remember to generate this and set it in "GitHub Secrets"
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
6 changes: 6 additions & 0 deletions docs/authors.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Authors / collaborators
=======================

``signature_mahalanobis_knn`` is a `DataSig <https://datasig.ac.uk/>`_ project and originally written by `Zhen Shao <https://github.com/sz85512678>`_ and `Ryan Chan <https://github.com/rchan26>`_.

For an up-to-date list of collaborators, please see the `GitHub repo <https://github.com/datasig-ac-uk/signature_mahalanobis_knn>`_ for this package.
62 changes: 41 additions & 21 deletions docs/conf.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,28 @@
# Configuration file for the Sphinx documentation builder.
#
# This file only contains a selection of the most common options. For a full
# list see the documentation:
# https://www.sphinx-doc.org/en/master/usage/configuration.html

from __future__ import annotations

import importlib.metadata

# Warning: do not change the path here. To use autodoc, you need to install the
# package first.

# -- Project information -----------------------------------------------------

project = "signature_mahalanobis_knn"
copyright = "2023, Ryan Chan"
author = "Ryan Chan"
copyright = "2023, DataSig"
author = "DataSig"
version = release = importlib.metadata.version("signature_mahalanobis_knn")

# -- General configuration ---------------------------------------------------

# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = [
"myst_parser",
"sphinx.ext.autodoc",
Expand All @@ -17,29 +33,33 @@
"sphinx_copybutton",
]

# Add any paths that contain templates here, relative to this directory.
templates_path = []

# Include both markdown and rst files
source_suffix = [".rst", ".md"]
exclude_patterns = [
"_build",
"**.ipynb_checkpoints",
"Thumbs.db",
".DS_Store",
".env",
".venv",
]

# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
# This pattern also affects html_static_path and html_extra_path.
exclude_patterns = ["_build", "**.ipynb_checkpoints", "Thumbs.db", ".DS_Store", ".env"]


# -- Options for HTML output -------------------------------------------------

# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
#
html_theme = "furo"

myst_enable_extensions = [
"colon_fence",
]
# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path: list[str] = []

intersphinx_mapping = {
"python": ("https://docs.python.org/3", None),
}

nitpick_ignore = [
("py:class", "_io.StringIO"),
("py:class", "_io.BytesIO"),
# -- Extension configuration -------------------------------------------------
myst_enable_extensions = [
"colon_fence",
"deflist",
]

always_document_param_types = True
17 changes: 0 additions & 17 deletions docs/index.md

This file was deleted.

32 changes: 32 additions & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@

The ``signature_mahalanobis_knn`` Python package
================================================

``signature_mahalanobis_knn``
-----------------------------

.. toctree::
:maxdepth: 2
:titlesonly:
:caption: API
:glob:

mahal_distance.rst
sig_mahal_knn.rst

.. toctree::
:maxdepth: 2
:titlesonly:
:caption: About
:glob:

authors.rst



Indices and tables
==================

* :ref:`genindex`
* :ref:`modindex`
* :ref:`search`
7 changes: 7 additions & 0 deletions docs/mahal_distance.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Mahalanobis distance
====================

.. automodule:: signature_mahalanobis_knn.Mahalanobis
:members:
:undoc-members:
:show-inheritance:
7 changes: 7 additions & 0 deletions docs/sig_mahal_knn.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Signature Mahalanobis KNN method for anomaly detection
======================================================

.. automodule:: signature_mahalanobis_knn.SignatureMahalanobisKNN
:members:
:undoc-members:
:show-inheritance:
3 changes: 2 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ classifiers = [
]
dynamic = ["version"]
dependencies = [
"sktime@git+https://github.com/sz85512678/sktime",
# "sktime@git+https://github.com/sz85512678/sktime",
"sktime",
"numpy",
"scikit-learn",
"matplotlib",
Expand Down

0 comments on commit a24bfbf

Please sign in to comment.