reload_pimms() reloads the entire pimms module and returns it.

def reload_pimms():
    '''
    reload_pimms() reloads the entire pimms module and returns it.
    '''
    import sys, six
    try:    from importlib import reload
    except: from imp       import reload
    reload(sys.modules['pimms.util'])
    reload(sys.modules['pimms.table'])
    reload(sys.modules['pimms.immutable'])
    reload(sys.modules['pimms.calculation'])
    reload(sys.modules['pimms.cmdline'])
    reload(sys.modules['pimms'])
    return sys.modules['pimms']