Skip to content

Commit

Permalink
Merge pull request #278 from juaml/doc/joblib
Browse files Browse the repository at this point in the history
[DOC] Add doc on joblib + joblib_htcondor
  • Loading branch information
fraimondo authored Oct 23, 2024
2 parents 6393826 + a123b2d commit 8793197
Show file tree
Hide file tree
Showing 9 changed files with 568 additions and 37 deletions.
1 change: 1 addition & 0 deletions docs/changes/newsfragments/278.doc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Include documentation on how to use the `joblib`_ and `joblib-htcondor`_ library to parallelize computation by `Fede Raimondo`_
37 changes: 0 additions & 37 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -211,42 +211,6 @@

# -- Sphinx-Gallery configuration --------------------------------------------


class SubSectionTitleOrder:
"""Sort example gallery by title of subsection.
Assumes README.txt exists for all subsections and uses the subsection with
dashes, '---', as the adornment.
"""

def __init__(self, src_dir):
self.src_dir = src_dir
self.regex = re.compile(r"^([\w ]+)\n-", re.MULTILINE)

def __repr__(self):
return f"<{self.__class__.__name__}>"

def __call__(self, directory):
src_path = os.path.normpath(os.path.join(self.src_dir, directory))

# Forces Release Highlights to the top
if os.path.basename(src_path) == "release_highlights":
return "0"

readme = os.path.join(src_path, "README.txt")

try:
with open(readme) as f:
content = f.read()
except FileNotFoundError:
return directory

title_match = self.regex.search(content)
if title_match is not None:
return title_match.group(1)
return directory


ex_dirs = [
"00_starting",
"01_model_comparison",
Expand All @@ -269,7 +233,6 @@ def __call__(self, directory):
"examples_dirs": example_dirs,
"gallery_dirs": gallery_dirs,
"nested_sections": True,
"subsection_order": SubSectionTitleOrder("../examples"),
"filename_pattern": "/(plot|run)_",
"download_all_examples": False,
}
Expand Down
Binary file added docs/images/joblib_htcondor/condor_q.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/joblib_htcondor/ui_main.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/joblib_htcondor/ui_open.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/joblib_htcondor/ui_stacked.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions docs/links.inc
Original file line number Diff line number Diff line change
Expand Up @@ -43,3 +43,5 @@
.. _`scikit-optimize`: https://scikit-optimize.readthedocs.io/en/stable/
.. _`Optuna`: https://optuna.org
.. _`optuna_integration`: https://github.com/optuna/optuna-integration
.. _`Joblib`: https://joblib.readthedocs.io/en/stable/
.. _`joblib-htcondor`: https://github.com/juaml/joblib-htcondor
1 change: 1 addition & 0 deletions docs/selected_deeper_topics/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,4 @@ Selected deeper topics
cross_validation_splitter.rst
stacked_models.rst
CBPM.rst
joblib.rst
Loading

0 comments on commit 8793197

Please sign in to comment.