colour.utilities.handle_numpy_errors

colour.utilities.handle_numpy_errors(**kwargs)[source]

Decorator for handling Numpy errors.

Parameters

**kwargs (dict, optional) – Keywords arguments.

Returns

Return type

object

References

[KPK11]

Examples

>>> import numpy
>>> @handle_numpy_errors(all='ignore')
... def f():
...     1 / numpy.zeros(3)
>>> f()