Skip to content
Snippets Groups Projects
Commit d5677501 authored by Baptiste Bauvin's avatar Baptiste Bauvin
Browse files

Merged private algos

parents b2d5c3f8 832d5450
Branches
No related tags found
No related merge requests found
Showing
with 179 additions and 141 deletions
TODO
*.pyc
.idea/**
ipynb/.ipynb_checkpoints/**
docs/source/monomulti/.ipynb_checkpoints/**
results/*
data/*
Data/*
multiview_platform/MonoMultiviewClassifiers/Results/*
multiview_platform/tests/temp_tests/**
multiview-machine-learning-omis.iml
multiview_platform.egg-inf*
build*
dist*
multiview_platform/.idea/*
.gitignore
multiview_platform/examples/results/example_1/*
multiview_platform/examples/results/example_2_1_1/*
multiview_platform/examples/results/example_2_1_2/*
multiview_platform/examples/results/example_2_2_1/*
multiview_platform/examples/results/example_2_3/*
multiview_platform/examples/results/example_3/*
multiview_platform/examples/results/example_4/*
multiview_platform/examples/results/example_5/*
......@@ -6,6 +6,10 @@ tests:
script:
- pip3 install -e . --no-deps
- pytest-3
coverage: '/^TOTAL.+?(\d+\%)$/'
artifacts:
paths:
- htmlcov/
# generate the documentation
doc:
......@@ -18,8 +22,8 @@ doc:
script:
- export LC_ALL=$(locale -a | grep en_US)
- export LANG=$(locale -a | grep en_US)
- pip3 install -e . --no-deps
- sphinx-apidoc -o docs/source multiview_platform
- pip3 install -e .[doc]
- sphinx-apidoc -o docs/source summit
- cd docs/source
- sphinx-build -b html . ../build
- cd ../..
......@@ -27,6 +31,7 @@ doc:
artifacts:
paths:
- public
- htmlcov
# project public
pages:
......@@ -38,12 +43,17 @@ pages:
script:
- export LC_ALL=$(locale -a | grep en_US)
- export LANG=$(locale -a | grep en_US)
- pip3 install -e . --no-deps
- sphinx-apidoc -o docs/source multiview_platform
- pip3 install -e .[doc]
- pytest-3
- sphinx-apidoc -o docs/source summit
- cd docs/source
- sphinx-build -b html . ../build
- cd ../..
- cp -r ./docs/build public
- mkdir public/coverage
- mv htmlcov/index.html public/coverage/
- mv htmlcov/style.css public/coverage/
artifacts:
paths:
- public
[![License: GPL v3](https://img.shields.io/badge/License-GPL%20v3-blue.svg)](http://www.gnu.org/licenses/gpl-3.0)
[![Build Status](https://gitlab.lis-lab.fr/baptiste.bauvin/summit/badges/develop/pipeline.svg)](https://gitlab.lis-lab.fr/baptiste.bauvin/summit/badges/develop/pipeline.svg)
# Supervised MultiModal Integration Tool's Readme
This project aims to be an easy-to-use solution to run a prior benchmark on a dataset and evaluate mono- & multi-view algorithms capacity to classify it correctly.
## Getting Started
### Prerequisites (will be automatically installed)
To be able to use this project, you'll need :
* [Python 3.6](https://docs.python.org/3/)
And the following python modules :
* [numpy](http://www.numpy.org/), [scipy](https://scipy.org/),
* [matplotlib](http://matplotlib.org/) - Used to plot results,
* [sklearn](http://scikit-learn.org/stable/) - Used for the monoview classifiers,
* [joblib](https://pypi.python.org/pypi/joblib) - Used to compute on multiple threads,
* [h5py](https://www.h5py.org) - Used to generate HDF5 datasets on hard drive and use them to spare RAM,
* [pickle](https://docs.python.org/3/library/pickle.html) - Used to store some results,
* [pandas](https://pandas.pydata.org/) - Used to manipulate data efficiently,
* [six](https://pypi.org/project/six/) -
* [m2r](https://pypi.org/project/m2r/) - Used to generate documentation from the readme,
* [docutils](https://pypi.org/project/docutils/) - Used to generate documentation,
* [pyyaml](https://pypi.org/project/PyYAML/) - Used to read the config files,
* [plotly](https://plot.ly/) - Used to generate interactive HTML visuals,
* [tabulate](https://pypi.org/project/tabulate/) - Used to generated the confusion matrix.
### Installing
Once you cloned the project from the [gitlab repository](https://gitlab.lis-lab.fr/baptiste.bauvin/summit/), you just have to use :
```
cd path/to/summit/
pip install -e .
```
In the `summit` directory to install SuMMIT and its dependencies.
### Running on simulated data
In order to run it you'll need to try on **simulated** data with the command
```python
from multiview_platform.execute import execute
execute("example 1")
```
This will run the first example.
For more information about the examples, see the [documentation](http://baptiste.bauvin.pages.lis-lab.fr/summit/).
Results will be stored in the results directory of the installation path :
`path/to/summit/multiview_platform/examples/results`.
The documentation proposes a detailed interpretation of the results through [6 tutorials](http://baptiste.bauvin.pages.lis-lab.fr/summit/).
### Discovering the arguments
All the arguments of the platform are stored in a YAML config file. Some config files are given as examples.
The file stored in `summit/config_files/config.yml` is documented and it is highly recommended
to read it carefully before playing around with the parameters.
You can create your own configuration file. In order to run the platform with it, run :
```python
from multiview_platform.execute import execute
execute(config_path="/absolute/path/to/your/config/file")
```
For further information about classifier-specific arguments, see the [documentation](http://baptiste.bauvin.pages.lis-lab.fr/summit/).
### Dataset compatibility
In order to start a benchmark on your own dataset, you need to format it so SuMMIT can use it. To do so, a [python script](https://gitlab.lis-lab.fr/baptiste.bauvin/summit/-/blob/master/format_dataset.py) is provided.
For more information, see [Example 6](http://baptiste.bauvin.pages.lis-lab.fr/summit/tutorials/example4.html)
### Running on your dataset
Once you have formatted your dataset, to run SuMMIT on it you need to modify the config file as
```yaml
name: ["your_file_name"]
*
pathf: "path/to/your/dataset"
```
This will run a full benchmark on your dataset using all available views and labels.
It is highly recommended to follow the documentation's [tutorials](http://baptiste.bauvin.pages.lis-lab.fr/summit/tutorials/index.html) to learn the use of each parameter.
## Author
* **Baptiste BAUVIN**
### Contributors
* **Dominique BENIELLI**
* **Alexis PROD'HOMME**
.. |pipeline| image:: https://gitlab.lis-lab.fr/baptiste.bauvin/summit/badges/master/pipeline.svg
:alt: Pipeline status
.. |license| image:: https://img.shields.io/badge/License-GPL%20v3-blue.svg
:target: http://www.gnu.org/licenses/gpl-3.0
:alt: License: GPL v3
.. |coverage| image:: https://gitlab.lis-lab.fr/baptiste.bauvin/summit/badges/master/coverage.svg
:target: http://baptiste.bauvin.pages.lis-lab.fr/summit/coverage/index.html
:alt: Coverage
|pipeline| |license| |coverage|
Supervised MultiModal Integration Tool's Readme
===============================================
This project aims to be an easy-to-use solution to run a prior benchmark on a dataset and evaluate mono- & multi-view algorithms capacity to classify it correctly.
Getting Started
---------------
SuMMIT has been designed and uses continuous integration for Linux platforms (ubuntu 18.04), but we try to keep it as compatible as possible with Mac and Windows.
+----------+-------------------+
| Platform | Last positive test|
+==========+===================+
| Linux | |pipeline| |
+----------+-------------------+
| Mac | 1st of May, 2020 |
+----------+-------------------+
| Windows | 1st of May, 2020 |
+----------+-------------------+
Prerequisites
<<<<<<<<<<<<<
To be able to use this project, you'll need :
* `Python 3 <https://docs.python.org/3/>`_
And the following python modules will be automatically installed :
* `numpy <http://www.numpy.org/>`_, `scipy <https://scipy.org/>`_,
* `matplotlib <http://matplotlib.org/>`_ - Used to plot results,
* `sklearn <http://scikit-learn.org/stable/>`_ - Used for the monoview classifiers,
* `joblib <https://pypi.python.org/pypi/joblib>`_ - Used to compute on multiple threads,
* `h5py <https://www.h5py.org>`_ - Used to generate HDF5 datasets on hard drive and use them to spare RAM,
* `pickle <https://docs.python.org/3/library/pickle.html>`_ - Used to store some results,
* `pandas <https://pandas.pydata.org/>`_ - Used to manipulate data efficiently,
* `six <https://pypi.org/project/six/>`_ -
* `m2r <https://pypi.org/project/m2r/>`_ - Used to generate documentation from the readme,
* `docutils <https://pypi.org/project/docutils/>`_ - Used to generate documentation,
* `pyyaml <https://pypi.org/project/PyYAML/>`_ - Used to read the config files,
* `plotly <https://plot.ly/>`_ - Used to generate interactive HTML visuals,
* `tabulate <https://pypi.org/project/tabulate/>`_ - Used to generated the confusion matrix.
Installing
<<<<<<<<<<
Once you cloned the project from the `gitlab repository <https://gitlab.lis-lab.fr/baptiste.bauvin/summit/>`_, you just have to use :
.. code:: bash
cd path/to/summit/
pip install -e .
In the `summit` directory to install SuMMIT and its dependencies.
Running the tests
<<<<<<<<<<<<<<<<<
To run the test suite of SuMMIT, run :
.. code:: bash
cd path/to/summit
pip install -e .[dev]
pytest
The coverage report is automatically generated and stored in the ``htmlcov/`` directory
Building the documentation
<<<<<<<<<<<<<<<<<<<<<<<<<<
To locally build the `documentation <http://baptiste.bauvin.pages.lis-lab.fr/summit/index.html>`_ run :
.. code:: bash
cd path/to/summit
pip install -e .[doc]
python setup.py build_sphinx
The built html files will be stored in ``path/to/summit/build/sphinx/html``
Running on simulated data
<<<<<<<<<<<<<<<<<<<<<<<<<
For your first go with SuMMIT, you can run it on simulated data with
.. code:: bash
python
>>> from summit.execute import execute
>>> execute("example 1")
This will run the benchmark of `documentation's Example 1 <http://baptiste.bauvin.pages.lis-lab.fr/summit/tutorials/example1.html>`_.
For more information about the examples, see the `documentation <http://baptiste.bauvin.pages.lis-lab.fr/summit/index.html>`_.
Results will, by default, be stored in the results directory of the installation path :
``path/to/summit/multiview_platform/examples/results``.
The documentation proposes a detailed interpretation of the results and arguments of SuMMIT through `6 tutorials <http://baptiste.bauvin.pages.lis-lab.fr/summit/>`_.
Dataset compatibility
<<<<<<<<<<<<<<<<<<<<<
In order to start a benchmark on your own dataset, you need to format it so SuMMIT can use it. To do so, a `python script <https://gitlab.lis-lab.fr/baptiste.bauvin/summit/-/blob/master/format_dataset.py>`_ is provided.
For more information, see `Example 5 <http://baptiste.bauvin.pages.lis-lab.fr/summit/tutorials/example5.html>`_
Running on your dataset
+++++++++++++++++++++++
Once you have formatted your dataset, to run SuMMIT on it you need to modify the config file as
.. code:: yaml
name: ["your_file_name"]
pathf: "path/to/your/dataset"
It is however highly recommended to follow the documentation's `tutorials <http://baptiste.bauvin.pages.lis-lab.fr/summit/tutorials/index.html>`_ to learn the use of each parameter.
Authors
-------
* **Baptiste BAUVIN**
* **Dominique BENIELLI**
* **Alexis PROD'HOMME**
# The base configuration of the benchmark
log: True
name: ["digits"]
name: ["mnist_0_9_train"]
label: "_"
file_type: ".hdf5"
views:
pathf: "/home/baptiste/Documents/Datasets/Digits/"
views: ["NIMST_data", ]
pathf: "/home/baptiste/Documents/Datasets/MNist/"
nice: 0
random_state: 42
random_state: 43
nb_cores: 1
full: True
full: False
debug: True
add_noise: False
noise_std: 0.0
......@@ -17,15 +17,18 @@ track_tracebacks: False
# All the classification-realted configuration options
multiclass_method: "oneVersusOne"
split: 0.75
split: 0.96
nb_folds: 5
nb_class:
nb_class: 2
classes:
type: ["multiview",]
algos_monoview: ["decision_tree", "random_forest"]
type: ["monoview",]
algos_monoview: ["hm_gb_cbound","cb_boost"]
algos_multiview: ["mumbo","mvml"]
stats_iter: 2
metrics: ["accuracy_score", "f1_score"]
metric_princ: "accuracy_score"
hps_type: "randomized_search-equiv"
hps_iter: 2
\ No newline at end of file
stats_iter: 1
metrics:
zero_one_loss: {}
f1_score: {}
metric_princ: "zero_one_loss"
hps_type: "None"
hps_args:
n_iter: 2
\ No newline at end of file
# Sphinx build info version 1
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
config: 2563b85d273675f134744be21dec5485
config: 50408771402db3b72187e770c685f635
tags: 645f666f9bcd5a90fca523b33c5a78b7
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment