Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removed need for copy_build_artifacts in the doc build process. #1100

Merged
merged 9 commits into from
Aug 15, 2024
Prev Previous commit
cleanup
robfalck committed Aug 15, 2024
commit 2a56af72069156eb88d1192e5b45da970e9ca378
12 changes: 7 additions & 5 deletions docs/dymos_book/faq/use_partial_coloring.ipynb
Original file line number Diff line number Diff line change
@@ -260,6 +260,7 @@
"\n",
" p.driver = om.pyOptSparseDriver()\n",
" p.driver.options['optimizer'] = 'IPOPT'\n",
" p.driver.options['print_results'] = False\n",
"\n",
" p.driver.opt_settings['max_iter'] = 500\n",
" p.driver.opt_settings['print_level'] = 0\n",
@@ -340,7 +341,7 @@
" p.setup()\n",
"\n",
" p['traj.phase0.t_initial'] = 0.0\n",
" p['traj.phase0.t_duration'] = 500\n",
" p['traj.phase0.t_duration'] = 400\n",
"\n",
" p['traj.phase0.states:r'] = phase.interp('r', [0.0, 50000.0])\n",
" p['traj.phase0.states:h'] = phase.interp('h', [100.0, 20000.0])\n",
@@ -367,20 +368,21 @@
" om_version_tup = tuple((int(s) for s in om_version.split('-')[0].split('.')))\n",
"\n",
" # Handle the output directory behavior change as of OpenMAO 3.34.3-dev\n",
" stfd = '_fd' if fd else ''\n",
" stpc = '_pc' if pc else ''\n",
" if om_version_tup > (3, 34, 2):\n",
" stfd = '_fd' if fd else ''\n",
" stpc = '_pc' if pc else ''\n",
" saved_coloring_dir = f'coloring_files{stfd}{stpc}'\n",
" if os.path.exists(saved_coloring_dir):\n",
" shutil.rmtree(saved_coloring_dir)\n",
" shutil.move(p.get_coloring_dir(mode='output'), saved_coloring_dir)\n",
" _view_coloring(os.path.join(saved_coloring_dir, 'total_coloring.pkl'))\n",
" else:\n",
" coloring_dir = f'coloring_files{stfd}{stpc}'\n",
" if fd or pc:\n",
" if os.path.exists(coloring_dir):\n",
" shutil.rmtree(coloring_dir)\n",
" shutil.move('coloring_files', coloring_dir)\n",
" _view_coloring(os.path.join(saved_coloring_dir, 'total_coloring.pkl'))"
" shutil.move('coloring_files', coloring_dir)\n",
" _view_coloring(os.path.join(coloring_dir, 'total_coloring.pkl'))"
]
},
{