omfit-python 2020.12.2.22.59
omfit_python
Requires Python: >=3.6

**PYTHON** files used as part of the OMFIT project: https://omfit.io/

Provides:
=========
* _OMFITpython
* OMFITpythonTask
* OMFITpythonGUI
* OMFITpythonPlot
* OMFITpythonTest
* parallel_environment
* execGlobLoc
* defaultVars
* OMFITworkDir
* for_all_modules
* import_all_private
* import_mayavi
* _lock_OMFIT_preferences
* OMFITconsoleDict
* OMFITscriptsDict
* OMFITreloadedDict
* help
* omfit_pydocs
* threaded_logic

Requires:
=========
* matplotlib>=3.1,!=3.2.1,!=3.2.2
* numpy>=1.12
* uncertainties>=3
* xarray>=0.10.8
* omfit_base==2020.12.2.22.59
* omfit_ascii==2020.12.2.22.59
* omfit_path==2020.12.2.22.59
* omfit_commonclasses==2020.12.2.22.59

Authors:
=========
https://omfit.io/contributors.html

Documentation:
==============
_OMFITpython
------------
Python script

OMFITpythonTask
---------------
Python script for OMFIT tasks

OMFITpythonGUI
--------------
Python script for OMFIT gui

OMFITpythonPlot
---------------

    Python script for OMFIT plots.
    Differently from the OMFITpythonTask class, the OMFITpythonPlot will not refresh the OMFIT GUIs
    though the OMFIT tree GUI itself will still be updated.

    Use .plot() method for overplotting (called by pressing <Shift-Return> in the OMFIT GUI)

    Use .plotFigure() method for plotting in new figure (called by pressing <Return> in the OMFIT GUI)

    When a single script should open more than one figure, it's probably best to use objects
    of the class :class:`OMFITpythonTask` and manually handling oveplotting and opening of new figures.
    To use a OMFITpythonTask object for plotting, it's useful to call the .runNoGUI method
    which prevents update of the GUIs that are open.
    

OMFITpythonTest
---------------

    Python script for OMFIT regression tests
    

parallel_environment
--------------------

    This environment is used as part of OMFITpythonTask.prun to make it safe for multiprocessing
    

execGlobLoc
-----------
N/A

defaultVars
-----------

    Function used to setup default variables in an OMFIT script (of type
    OMFITpythonTask, OMFITpythonTest, OMFITpythonGUI, or OMFITpythonPlot)
    Really the magic function that allows OMFIT scripts to act as a function

    :param \**kw: keyword parameter dictionary with default value

    :return: dictionary with variables passed by the user

    To be used as
    dfv = defaultVars(var1_i_want_to_define=None, var2_i_want_to_define=None)
    and then later in the script, one can use var1_i_want_to_define or var2_i_want_to_define

    Implications of python passing variables by reference are noted in
    https://medium.com/@meghamohan/mutable-and-immutable-side-of-python-c2145cf72747
    

OMFITworkDir
------------

    This is a convenience function which returns the string for the working directory of OMFIT modules (remote or local).
    The returned directory string is compatible with parallel running of modules. The format used is:
    [server_OMFIT_working_directory]/[projectID]/[mainsettings_runID]/[module_tree_location]-[module_runid]/[p_multiprocessing_folder]/

    :param root: root of the module (or string)

    :param server: remote server. If empty string or None, then the local working directory is returned.

    :return: directory string
    

for_all_modules
---------------

    This is a utility function (to be used by module developers) which can be used to execute the same command on all of the modules
    Note that this script will overwrite the content of your OMFIT tree.

    :param doThis: python script to execute.
       In this script the following variables are defined
       ``module`` contains the reference to the current module being processed,
       ``moduleID`` the moduleID,
       ``moduleLocation`` the location of the module in the tree
       ``moduleFile`` the module filename

    :param deploy: save the modules back on their original location

    :param skip: skip modules that are already in the tree

    :return: None
    

import_all_private
------------------

    This function is used to import all private attributes from a module
    Can be used in a script like this::

    >> locals().update(import_all_private('classes.OMFITx'))
    

import_mayavi
-------------

    This function attempts to import mayavi, mayavi.mlab
    while avoiding known institutional installation pitfalls
    as well as known tk vs qt backend issues.

    :param verbose: bool. Prints a warning message if mayavi can't be imported
    :return: obj. mayavi if it was successfully imported, None if not
    

_lock_OMFIT_preferences
-----------------------
N/A

OMFITconsoleDict
----------------

    Same class of dict, but is not saved when a project is saved
    This class is used to handle namespaces, which should not alter the ._OMFITparent, ._OMFITkeyName of objects which are used within of the namespace
    

OMFITscriptsDict
----------------

    Same class of dict, but is not saved when a project is saved
    This class is used to handle namespaces, which should not alter the ._OMFITparent, ._OMFITkeyName of objects which are used within of the namespace
    

OMFITreloadedDict
-----------------

    Same class of dict, but is not saved when a project is saved
    This class is used to handle namespaces, which should not alter the ._OMFITparent, ._OMFITkeyName of objects which are used within of the namespace
    

help
----
N/A

omfit_pydocs
------------
N/A

threaded_logic
--------------
N/A