HiggsAnalysis-KITHiggsToTauTau
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros
uncertainties.unumpy.core Namespace Reference

Classes

class  CallableStdDevs
 Matrix class. More...
 
class  matrix
 

Functions

def unumpy_to_numpy_matrix
 
def nominal_values
 Return the nominal values of the numbers in NumPy array arr. More...
 
def std_devs
 Return the standard deviations of the numbers in NumPy array arr. More...
 
def derivative
 
def wrap_array_func
 
def uarray
 Arrays. More...
 
def array_derivative
 
def func_with_deriv_to_uncert_func
 
def inv_with_derivatives
 Matrix inverse. More...
 
def pinv_with_derivatives
 Matrix pseudo-inverse. More...
 
def pinv
 
def umatrix
 Constructs a matrix that contains numbers with uncertainties. More...
 
def define_vectorized_funcs
 Defines vectorized versions of functions from uncertainties.umath_core. More...
 

Variables

list __all__
 
tuple to_nominal_values
 Utilities: More...
 
tuple to_std_devs
 
tuple inv = func_with_deriv_to_uncert_func(inv_with_derivatives)
 
list pinv_default = numpy.linalg.pinv.__defaults__[0]
 
tuple pinv_with_uncert = func_with_deriv_to_uncert_func(pinv_with_derivatives)
 
tuple pinv = uncert_core.set_doc(""" Version of numpy.linalg.pinv that works with array-like objects that contain numbers with uncertainties. The result is a unumpy.matrix if numpy.linalg.pinv would return a matrix for the array of nominal values. Analytical formulas are used. Original documentation: %s """ % numpy.linalg.pinv.__doc__)
 

Function Documentation

def uncertainties.unumpy.core.array_derivative (   array_like,
  var 
)
def uncertainties.unumpy.core.define_vectorized_funcs ( )

Defines vectorized versions of functions from uncertainties.umath_core.

Some functions have their name translated, so as to follow NumPy's convention math.acos -> numpy.arccos).

def uncertainties.unumpy.core.derivative (   u,
  var 
)
def uncertainties.unumpy.core.func_with_deriv_to_uncert_func (   func_with_derivatives)
def uncertainties.unumpy.core.inv_with_derivatives (   arr,
  input_type,
  derivatives 
)

Matrix inverse.

Defines the matrix inverse and its derivatives.

See the definition of func_with_deriv_to_uncert_func() for its
detailed semantics.
def uncertainties.unumpy.core.nominal_values (   arr)

Return the nominal values of the numbers in NumPy array arr.

Elements that are not numbers with uncertainties (derived from a class from this module) are passed through untouched (because a numpy.array can contain numbers with uncertainties and pure floats simultaneously).

If arr is of type unumpy.matrix, the returned array is a numpy.matrix, because the resulting matrix does not contain numbers with uncertainties.

def uncertainties.unumpy.core.pinv (   array_like,
  rcond = pinv_default 
)
def uncertainties.unumpy.core.pinv_with_derivatives (   arr,
  input_type,
  derivatives,
  rcond 
)

Matrix pseudo-inverse.

Defines the matrix pseudo-inverse and its derivatives.

Works with real or complex matrices.

See the definition of func_with_deriv_to_uncert_func() for its
detailed semantics.
def uncertainties.unumpy.core.std_devs (   arr)

Return the standard deviations of the numbers in NumPy array arr.

Elements that are not numbers with uncertainties (derived from a class from this module) are passed through untouched (because a numpy.array can contain numbers with uncertainties and pure floats simultaneously).

If arr is of type unumpy.matrix, the returned array is a numpy.matrix, because the resulting matrix does not contain numbers with uncertainties.

def uncertainties.unumpy.core.uarray (   nominal_values,
  std_devs = None 
)

Arrays.

def uncertainties.unumpy.core.umatrix (   nominal_values,
  std_devs = None 
)

Constructs a matrix that contains numbers with uncertainties.

The arguments are the same as for uarray(...): nominal values, and standard deviations.

The returned matrix can be inverted, thanks to the fact that it is a unumpy.matrix object instead of a numpy.matrix one.

def uncertainties.unumpy.core.unumpy_to_numpy_matrix (   arr)
def uncertainties.unumpy.core.wrap_array_func (   func)

Variable Documentation

list uncertainties.unumpy.core.__all__
Initial value:
1 = [
2  # Factory functions:
3  'uarray', 'umatrix',
4 
5  # Utilities:
6  'nominal_values', 'std_devs',
7 
8  # Classes:
9  'matrix'
10  ]
tuple uncertainties.unumpy.core.inv = func_with_deriv_to_uncert_func(inv_with_derivatives)
tuple uncertainties.unumpy.core.pinv = uncert_core.set_doc(""" Version of numpy.linalg.pinv that works with array-like objects that contain numbers with uncertainties. The result is a unumpy.matrix if numpy.linalg.pinv would return a matrix for the array of nominal values. Analytical formulas are used. Original documentation: %s """ % numpy.linalg.pinv.__doc__)
list uncertainties.unumpy.core.pinv_default = numpy.linalg.pinv.__defaults__[0]
tuple uncertainties.unumpy.core.pinv_with_uncert = func_with_deriv_to_uncert_func(pinv_with_derivatives)
tuple uncertainties.unumpy.core.to_nominal_values
Initial value:
1 = numpy.vectorize(
2  uncert_core.nominal_value,
3  otypes=[float], # Because vectorize() has side effects (dtype setting)
4  doc=("Return the nominal value of the numbers with uncertainties contained"
5  " in a NumPy (or unumpy) array (this includes matrices)."))

Utilities:

tuple uncertainties.unumpy.core.to_std_devs
Initial value:
1 = numpy.vectorize(
2  uncert_core.std_dev,
3  otypes=[float], # Because vectorize() has side effects (dtype setting)
4  doc=("Return the standard deviation of the numbers with uncertainties"
5  " contained in a NumPy array, or zero for other objects."))