Skip to content

Commit

Permalink
Updated: Updated docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Caparrini committed Oct 25, 2024
1 parent 0229c97 commit 32f0aa6
Show file tree
Hide file tree
Showing 13 changed files with 124 additions and 34 deletions.
3 changes: 3 additions & 0 deletions docs/_static/custom.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
img {
background-color: transparent !important;
}
13 changes: 13 additions & 0 deletions docs/_static/custom.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
document.addEventListener("DOMContentLoaded", function() {
// Select the toc-item and its ul (if exists)
const tocItem = document.querySelector('.bd-toc-item ul');

// Check if the ul doesn't exist
if (!tocItem) {
// Hide the entire sidebar if the toc ul is not found
const sidebar = document.querySelector('.bd-sidebar');
if (sidebar) {
sidebar.style.display = 'none';
}
}
});
19 changes: 19 additions & 0 deletions docs/api/domain/hyperspace.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
hyperspace
==========

The `hyperspace` module provides classes and functions for defining search spaces for hyperparameters.
An user should use the :class:`~mloptimizer.interfaces.HyperparameterSpaceBuilder` class to
define the search space for hyperparameters.

.. autosummary::

~mloptimizer.domain.hyperspace.Hyperparam
~mloptimizer.domain.hyperspace.HyperparameterSpace


.. toctree::
:maxdepth: 4
:caption: Contents:

hyperspace/hyperparam
hyperspace/hyperparameter_space
14 changes: 14 additions & 0 deletions docs/api/domain/hyperspace/hyperparam.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
Hyperparam
----------

This class provides a way to define hyperparameters for a machine learning model.



.. autoclass:: mloptimizer.domain.hyperspace.Hyperparam
:members:
:undoc-members:
:show-inheritance:
:exclude-members: __init__


13 changes: 13 additions & 0 deletions docs/api/domain/hyperspace/hyperparameter_space.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
HyperparameterSpace
-------------------

This class provides a way to define search spaces for hyperparameters.


.. autoclass:: mloptimizer.domain.hyperspace.HyperparameterSpace
:members:
:undoc-members:
:show-inheritance:
:exclude-members: __init__


15 changes: 14 additions & 1 deletion docs/api/interfaces/genetic_search.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,17 @@ This class provides a genetic algorithm-based optimization framework.
:show-inheritance:
:exclude-members: __init__


Gallery examples
----------------
See these examples for practical usage of this class:

.. list-table::
:widths: 25 75
:header-rows: 1

* - Example
- Description
* - :ref:`sphx_glr_auto_examples_plot_quickstart.py`
- Demonstrates how to use GeneticSearch for hyperparameter tuning.
* - :ref:`sphx_glr_auto_examples_plot_xgboost_hyperparam_opt_comparison.py`
- Compares GeneticSearch with GridSearchCV, RandomizedSearchCV and Bayesian Search.
11 changes: 11 additions & 0 deletions docs/api/mloptimizer.domain.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
domain
======

The `domain` contains the core classes and functions for building and optimizing machine learning models.


.. toctree::
:maxdepth: 4
:caption: Contents:

domain/hyperspace
3 changes: 2 additions & 1 deletion docs/api/mloptimizer.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ The `mloptimizer` package provides interfaces for building and optimizing machin
It includes tools for defining search spaces, managing optimization processes, and more.

.. toctree::
:maxdepth: 4
:maxdepth: 6
:caption: Contents:

mloptimizer.interfaces
mloptimizer.domain
7 changes: 5 additions & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,9 @@
# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output

html_theme = 'pydata_sphinx_theme'
# html_static_path = ['_static']
html_static_path = ['_static']
html_css_files = ["custom.css"]
html_js_files = ["custom.js"]

image_scrapers = ('matplotlib', plotly_sg_scraper,)

Expand All @@ -84,7 +86,7 @@
napoleon_google_docstring = True
napoleon_numpy_docstring = True

html_show_sourcelink = False
html_show_sourcelink = True
set_type_checking_flag = True

sphinx_gallery_conf = {
Expand All @@ -101,6 +103,7 @@
"show_nav_level": 2, # Control the navigation levels displayed
"show_prev_next": False, # Hide previous/next links
"navigation_depth": 3, # Set navigation depth to control sidebar depth
"navbar_align": "left", # Align the navbar to the left
"icon_links": [
{
"name": "GitHub", # The name that will appear on hover
Expand Down
31 changes: 4 additions & 27 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,38 +8,15 @@ Welcome to mloptimizer's documentation!


.. toctree::
:maxdepth: 1
:caption: Home:
:maxdepth: 4

readme_link

.. toctree::
:maxdepth: 1
:caption: User guide:

sections/introduction
sections/installation
sections/Basics/index
sections/Concepts/index
sections/install
sections/user_guide
api/api_reference
auto_examples/index
sections/mloptimizerUI

.. toctree::
:maxdepth: 3
:caption: API reference:

api/api_reference

.. toctree::
:maxdepth: 1
:caption: Development:

sections/development

.. toctree::
:maxdepth: 1
:caption: Releases:

sections/changelog


Expand Down
13 changes: 11 additions & 2 deletions docs/sections/installation.rst → docs/sections/install.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
====================
Installation
Install
====================
This package is available in the `Python Package Index
<http://pypi.python.org/pypi/mloptimizer>`__.
Expand Down Expand Up @@ -39,4 +39,13 @@ To install ``mloptimizer``, then simply run:

.. code:: bash
pip install mloptimizer
pip install mloptimizer
===============
Troubleshooting
===============

If you experience any unexpected issues during the installation of mloptimizer,
you’re welcome to submit a report to the `issue tracker <https://github.com/Caparrini/mloptimizer/issues>`_.
Before doing so, please review the commonly detected issues listed here.
Currently, there are no known installation issues.
13 changes: 13 additions & 0 deletions docs/sections/user_guide.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
.. _user_guide:

==========
User Guide
==========

.. toctree::
:maxdepth: 3
:numbered:

introduction
Basics/index
Concepts/index
3 changes: 2 additions & 1 deletion requirements_dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,5 @@ sphinxcontrib-mermaid
tensorflow>=2.12.0
tqdm
xgboost>=1.7.3
hyperopt
hyperopt
ucimlrepo

0 comments on commit 32f0aa6

Please sign in to comment.