notebook_utils.py#

Checking for interactive notebook mode.

openmdao.utils.notebook_utils.cite(reference)[source]

Return the citation of the given reference path.

Parameters:
referencestr

Dot path of desired class or function.

openmdao.utils.notebook_utils.display_source(reference, hide_doc_string=False)[source]

Display the source code of the given reference path to a function.

Parameters:
referencestr

Dot path of desired function.

hide_doc_stringbool

Option to hide the docstring.

openmdao.utils.notebook_utils.get_code(reference, hide_doc_string=False)[source]

Return the source code of the given reference path to a function.

Parameters:
referencestr

Dot path of desired function.

hide_doc_stringbool

Option to hide the docstring.

Returns:
IPython.display.Code

Source code of the given class or function.

openmdao.utils.notebook_utils.notebook_mode()[source]

Check if the environment is interactive.

Returns:
bool

True if the environment is an interactive notebook.

openmdao.utils.notebook_utils.show_options_table(reference, recording_options=False, options_dict='options')[source]

Return the options table of the given reference path.

Parameters:
referencestr or object

Dot path of desired class or function or an instance.

recording_optionsbool

If True, display recording options instead of options.

options_dictstr

The string name of the attribute of the reference object that provides to OptionsDictionary.

Returns:
IPython.display

Options table of the given class or function.