Adding a new estimator to IDTxl - pwollstadt/IDTxl GitHub Wiki

IDTxl is easily extendable through the easy addition of new core estimators. A new estimator should implement the abstract Estimator() class with abstract methods

  • estimate(): should take data as individual parameters, as well as additional parameters; each data variable should be a 2D numpy array with size [realisations x var. dimension] for serial estimators, and size [(realisations * no. chunks) x var. dimension] for parallel estimators; (the number of chunks has to be passed as an additional argument, see for example the OpenCL estimator module)
  • is_parallel(): return True if the estimator is parallel
  • is_analytic_null_estimator(): return True for analytic estimators

The module and class name should follow IDTxl's naming conventions: the module name should start with the prefixestimators_*, class names should consist of estimator name, data type, and estimated measure, e.g., JIDTKraskovCMI(). The estimator can then be used in network analysis algorithms by setting cmi_estimator to the estimator name.