IPython (utilipy.ipython)

Reference/API

utilipy.ipython Package

Functions for interacting with the IPython environment.

Methods

autoreload:

set_autoreload: set the notebook’s autoreload state for modules aimport: import a module with autoreload options

imports:

import_from_file run_imports import_base, import_extended, import_astropy, import_matplotlib aimport from .autoreload

notebook:

add_raw_code_toggle

plot:

configure_matplotlib

printing:

printmd / printMD printHTML printltx / printLaTeX

Returns

IPython: modules and functions

  • get_ipython

  • core.interactiveshell

    • InteractiveShell

    • .debugger.set_trace

  • display.display, Latex, Markdown, HTML

utilipy: modules and functions

  • ipython

    • autoreload.set_autoreload, aimport

    • .imports.run_imports, import_from_file

    • .notebook.add_raw_code_toggle

    • .plot.configure_matplotlib

    • .printing.printmd, printMD, printltx, printLaTeX

  • utils.logging.LogPrint, LogFile

Notes

will set the display setting to all output lines and set the matplotlib backend to inline with retina resolution InteractiveShell.ast_node_interactivity = "all" configure_matplotlib(backend='inline', figure_format='retina')

References

IPython 1

1

Fernando Pérez, Brian E. Granger, IPython: A System for Interactive Scientific Computing, Computing in Science and Engineering, vol. 9, no. 3, pp. 21-29, May/June 2007, doi:10.1109/MCSE.2007.53. URL: https://ipython.org

Functions

ipython_help()

Help for ipython module..

set_autoreload([reload_type])

Global imports setting.

aimport(*modules[, autoreload])

Jupyter magic aimport.

run_imports(*files[, is_relative, base, …])

Import file using IPython magic.

import_from_file(*files[, is_relative, …])

Run import(s) from a file(s).

add_raw_code_toggle()

Add a toggle for code cells when Notebook is exported to HTML.

printMD(s[, color, size, bold, italic, …])

Print in Markdown.

printLTX(s[, math, equation, matrix, label])

Print in LaTeX.