IPython Documentation

Table Of Contents

Previous topic

Module: parallel.factory

Next topic

Module: qt.base_frontend_mixin

This Page


This documentation is for an old version of IPython. You can find docs for newer versions here.

Module: parallel.util

some generic utilities for dealing with classes, urls, and serialization


  • Min RK

2 Classes

class IPython.parallel.util.Namespace

Bases: dict

Subclass of dict for attribute access to keys.

class IPython.parallel.util.ReverseDict(*args, **kwargs)

Bases: dict

simple double-keyed subset of dict methods.

__init__(*args, **kwargs)

16 Functions


decorator to log unhandled exceptions raised in a method.

For use wrapping on_recv callbacks, so that exceptions do not cause the stream to be closed.


boolean check for whether a string is a zmq url


validate a url for zeromq


validate a potentially nested collection of urls.


split a zmq url (tcp://ip:port) into (‘tcp’,’ip’,’port’).

IPython.parallel.util.disambiguate_ip_address(ip, location=None)

turn multi-ip interfaces ‘’ and ‘*’ into connectable ones, based on the location (default interpretation of location is localhost).

IPython.parallel.util.disambiguate_url(url, location=None)

turn multi-ip interfaces ‘’ and ‘*’ into connectable ones, based on the location (default interpretation is localhost).

This is for zeromq urls, such as tcp://*:10101.


decorator for making functions appear as interactively defined. This results in the function being linked to the user_ns as globals() instead of the module globals().


Selects and return n random ports that are available.


Relay interupt/term signals to children, for more solid process cleanup.

IPython.parallel.util.connect_logger(logname, context, iface, root='ip', loglevel=10)
IPython.parallel.util.connect_engine_logger(context, iface, engine, loglevel=10)
IPython.parallel.util.local_logger(logname, loglevel=10)
IPython.parallel.util.set_hwm(sock, hwm=0)

set zmq High Water Mark on a socket

in a way that always works for various pyzmq / libzmq versions.