{"id":32656704,"url":"https://github.com/openmdao/openmdao_book","last_synced_at":"2025-10-31T11:06:22.683Z","repository":{"id":51259105,"uuid":"341594381","full_name":"OpenMDAO/OpenMDAO_Book","owner":"OpenMDAO","description":null,"archived":false,"fork":false,"pushed_at":"2021-05-18T19:04:16.000Z","size":6202,"stargazers_count":3,"open_issues_count":0,"forks_count":8,"subscribers_count":6,"default_branch":"main","last_synced_at":"2024-03-26T02:24:17.179Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/OpenMDAO.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-02-23T15:11:09.000Z","updated_at":"2022-07-02T18:42:17.000Z","dependencies_parsed_at":"2022-09-23T12:22:28.388Z","dependency_job_id":null,"html_url":"https://github.com/OpenMDAO/OpenMDAO_Book","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/OpenMDAO/OpenMDAO_Book","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenMDAO%2FOpenMDAO_Book","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenMDAO%2FOpenMDAO_Book/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenMDAO%2FOpenMDAO_Book/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenMDAO%2FOpenMDAO_Book/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/OpenMDAO","download_url":"https://codeload.github.com/OpenMDAO/OpenMDAO_Book/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OpenMDAO%2FOpenMDAO_Book/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":281976636,"owners_count":26592973,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-31T02:00:07.401Z","response_time":57,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-10-31T11:06:21.006Z","updated_at":"2025-10-31T11:06:22.669Z","avatar_url":"https://github.com/OpenMDAO.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# OpenMDAO Book\n\nThis repo contains the prototype for new, more interactive documentation of OpenMDAO\nbased on [jupyter-book](https://jupyterbook.org/intro.html).\n\nFor now I've left in the default Jupyter-book files, which includes some\nuseful how-to information. OpenMDAO-specific documentation begins with `main.md`.\n\n## Pre-requisites\n\nYou will need to pip install `jupyter-book`.\nAlso, building the notebook seems to require Python 3.8.\n\n## Building\n\nFrom the repo root simply run the command below to build the docs from the root directory:\n\n```\npython build_jupyter_book.py\n```\n\n## Notebook Guidelines\n\n1. Each notebook should include this block at the top to import OpenMDAO if not already available.  This is necessary on the cloude-based notebook environments like colab.\n\n``` python3\ntry:\n    import openmdao.api as om\nexcept ImportError:\n    !python -m pip install openmdao[notebooks]\n    import openmdao.api as om\n```\n\nThis cell should be tagged with the following metadata.  The \"remove-input\" and \"remove-output\" tags prevent it from showing up in the documentation, and the \"hide_input\" portion collapses the input cell. To add a tag in Jupyter select `View` -\u003e `Cell Toolbar` -\u003e `Tags` add add any of the tags desired.\n\n``` yaml\n{\n  \"hide_input\": true,\n  \"tags\": [\n    \"remove-input\",\n    \"remove-output\",\n    \"active-ipynb\"\n  ],\n  \"trusted\": true\n}\n```\n\n2. Executed code in notebooks should be tested using the same assertions used in unittests.\n\nFor instance, in the paraboloid case we have:\n\n``` python3\n# This code block is hidden by default.\n# It exists to verify that the above code works correctly.\n\nfrom openmdao.utils.assert_utils import assert_near_equal\n\n# minimum value\nassert_near_equal(prob.get_val('paraboloid.f'), -27.33333, 1e-6);\n\n# location of the minimum\nassert_near_equal(prob.get_val('paraboloid.x'), 6.6667, 1e-4);\nassert_near_equal(prob.get_val('paraboloid.y'), -7.33333, 1e-4);\n```\n\nIt's not necessary to show this in the documentaiton, so remove it using the same\nmetadata tags above to hide.\n\n3. We will have Github actions to check for things like notebooks with output, missing import headers, and more.\n\n4. Since 'n2.html' files and other build artifacts need to be manually copied over to the output `_build` directory to make the docs, each example notebook should be kept in its own directory.\n\n### Troubleshooting\n\n- If you get an error `jupyter_client.kernelspec.NoSuchKernel: No such kernel named name-of-your-env`, this means your notebook's kernel is not set to `Python 3`. To fix this, select `Kernel` -\u003e `Change Kernel` -\u003e `Python 3` and then rebuild the docs.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopenmdao%2Fopenmdao_book","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fopenmdao%2Fopenmdao_book","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopenmdao%2Fopenmdao_book/lists"}