Skip to main content

Click me! ⬆️🖱️


MODI: Multicommodity Optimal Transport Dynamics on Images

ARXIV: 2205.02938 Treedom PyPI Version Run Pytest Open in Colab

⚠ Important note:
MODI is currently under reconstruction, thus you may find some inconsistencies in its documentation. In case you have problems using the code, please do not hesitate to contact us.

MODI (Multicommodity Optimal transport Dynamics on Images) is a Python implementation of the algorithms used in:

This is a scheme capable of performing supervised classification by finding multicommodity optimal transport paths between a pair of images.

If you use this code, please cite [1].
The symbol “*” denotes equal contribution.

Requirements

All the dependencies needed to run the algorithm can be installed using the following command:

pip install modi-flows

Please note that as of the latest release, the scikit-umfpack package is no longer a mandatory requirement for modi-flows. However, we highly recommend installing it to take advantage of enhanced performance. If you choose to install scikit-umfpack, it can be easily obtained from the conda repository:

conda install -c conda-forge scikit-umfpack

Now, you are ready to use the code! To do so, you can simply use the notebook dashboard.ipynb, from which you can access our solver.

Here's the directory structure:

What's included

  • src/modi_flows: Contains all the scripts necessary to run MODI.
  • notebooks: Holds user-friendly Jupyter notebooks, such as dashboard.ipynb, which allow you to interact with the code and visualize results.
  • data: Contains input data used in the examples.
    • input: Holds a small sample of images taken from [2]. These images can be preprocessed using code/dashboard.ipynb. The complete dataset can be downloaded as a .zip file from the Harvard Dataverse.
  • misc: Includes supplementary files such as the MODI poster.
  • tests: Contains test scripts to validate the functionality of the code.
  • docs: Contains documentation files, including Sphinx configuration and source files.

[2] Marco Seeland, Michael Rzanny, Nedal Alaqraa, Jana Wäldchen, and Patrick Mäder, Jena Flowers 30 Dataset, Harvard Dataverse (2017).

Contacts

For any issues or questions, feel free to contact us sending an email to:

License

Copyright (c) 2022 Alessandro Lonardi, Diego Baptista and Caterina De Bacco

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON INFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Metadata

Release files for modi-flows 0.1.7

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for modi-flows 0.1.7
File Size Uploaded Provenance
modi-flows-0.1.7.tar.gz 6.2 MB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for modi-flows 0.1.7
File Interpreter ABI Platform
modi_flows-0.1.7-py3-none-any.whl Python 3 none any Details

Total release size: 6.3 MB

Release files / modi-flows-0.1.7.tar.gz

Download URL modi-flows-0.1.7.tar.gz
Size 6.2 MB
Tags Source
SHA-256 checksum
How to use checksums
6939ffd6ffbad92264c0389a76bfe64cc934ac2282fce38795e81a475b17d637
BLAKE2b-256 checksum
How to use checksums
563436c4bfd16735582919cbbb3a35318eb515cf9d143b6c87bc6ebf5be522f2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.8.17

Release files / modi_flows-0.1.7-py3-none-any.whl

Download URL modi_flows-0.1.7-py3-none-any.whl
Size 15.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
bea70a07063fbb03eef381b7fcfb25ff34f5b1471a7e7428b7bec7f78b7f9877
BLAKE2b-256 checksum
How to use checksums
8cde422d9067990260bc39bf658457923a3e1a33c8b7cd10898c265478b10944
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.8.17

Security for modi-flows 0.1.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page