escore package

Submodules

escore.entry_points module

Project: Eskapade - A python-based package for data analysis.

Created: 2017-08-08

Description:
Collection of eskapade entry points
Authors:
KPMG Advanced Analytics & Big Data team, Amstelveen, The Netherlands

Redistribution and use in source and binary forms, with or without modification, are permitted according to the terms listed in the file LICENSE.

escore.entry_points.eskapade_bootstrap()

Generate Eskapade project structure.

Generate Eskapade link.

By default does not create init file.

escore.entry_points.eskapade_generate_macro()

Generate Eskapade macro.

escore.entry_points.eskapade_generate_notebook()

Generate Eskapade notebook.

escore.entry_points.eskapade_run()

Run Eskapade.

Top-level entry point for an Eskapade run started from the command line. Arguments specified by the user are parsed and converted to settings in the configuration object. Optionally, an interactive Python session is started when the run is finished.

escore.entry_points.eskapade_trial()

Run Eskapade tests.

We will keep this here until we’ve completed switch to pytest or nose and tox. We could also keep it, but I don’t like the fact that packages etc. are hard coded. Gotta come up with a better solution.

escore.exceptions module

Project: Eskapade - A python-based package for data analysis.

Created: 2017/03/31

Description:
Eskapade exceptions
Authors:
KPMG Advanced Analytics & Big Data team, Amstelveen, The Netherlands

Redistribution and use in source and binary forms, with or without modification, are permitted according to the terms listed in the file LICENSE.

exception escore.exceptions.AmbiguousFileType(path)

Bases: Exception

Exception raised if file type cannot be inferred

__init__(path)

Raise the exception

Parameters:path (str) – the path to file
exception escore.exceptions.MissingPackageError(message='', required_by='')

Bases: Exception

Exception raised if third-party package is missing.

__init__(message='', required_by='')

Set missing-package arguments.

Parameters:
  • message (str) – message to show when raised
  • required_by (str) – info on component that requires the package
exception escore.exceptions.UnhandledFileType(path, f_ext, file_type)

Bases: Exception

Exception raised if file type is not handled

__init__(path, f_ext, file_type)

Raise the exception

Parameters:
  • path (str) – the path to file
  • f_ext (str) – file extension as determined by splitting the path string
  • file_type (str) – user set file type. Options are {‘npy’, ‘npz’}

escore.resources module

Project: Eskapade - A python-based package for data analysis.

Created: 2017/08/23

Description:
Collection of helper functions to get fixtures, i.e. test data, ROOT/RooFit libs, and tutorials. These are mostly used by the (integration) tests.
Authors:
KPMG Advanced Analytics & Big Data team, Amstelveen, The Netherlands

Redistribution and use in source and binary forms, with or without modification, are permitted according to the terms listed in the file LICENSE.

escore.resources.template(name: str) → str

Return the full path filename of a tutorial.

Parameters:name (str) – The name of the template.
Returns:The full path filename of the tutorial.
Return type:str
Raises:FileNotFoundError – If the template cannot be found.
escore.resources.tutorial(name: str) → str

Return the full path filename of a tutorial.

Parameters:name (str) – The name of the tutorial.
Returns:The full path filename of the tutorial.
Return type:str
Raises:FileNotFoundError – If the tutorial cannot be found.

escore.utils module

Project: Eskapade - A python-based package for data analysis.

Created: 2016/11/08

Description:
Utility functions to collect Eskapade python modules e.g. functions to get correct Eskapade file paths and env variables
Authors:
KPMG Advanced Analytics & Big Data team, Amstelveen, The Netherlands

Redistribution and use in source and binary forms, with or without modification, are permitted according to the terms listed in the file LICENSE.

escore.utils.check_interactive_backend()

Check whether an interactive backend is required

escore.utils.collect_python_modules()

Collect Eskapade Python modules.

escore.utils.get_env_var(key)

Retrieve Eskapade-specific environment variables.

Parameters:key (str) – Eskapade-specific key to variable
Returns:environment variable value
Return type:str
escore.utils.in_ipynb()

Detect whether an Jupyter/Ipython-kernel is being run

Raises:NameError
escore.utils.in_tty()

Detect whether running in a terminal

escore.utils.set_matplotlib_backend(backend=None, batch=None, silent=True)

Set Matplotlib backend.

Parameters:
  • backend (str) – backend to set
  • batch (bool) – require backend to be non-interactive
  • silent (bool) – do not raise exception if backend cannot be set
Raises:

RuntimeError

escore.version module

THIS FILE IS AUTO-GENERATED BY ESKAPADE SETUP.PY.

Module contents