niftynet.evaluation.regression_evaluations module

This module defines built-in evaluation functions for regression applications

class BaseRegressionEvaluation(reader, app_param, eval_param)[source]

Bases: niftynet.evaluation.base_evaluations.BaseEvaluation

Interface for scalar regression metrics

layer_op(subject_id, data)[source]

Perform one evaluation calculation for one subject :param subject_id: subject identifier string :param data: a data dictionary as built by ImageReader :return: a list of pandas.DataFrame objects

metric(reg, ref)[source]

Computes a scalar value for the metric :param reg: np.array with inferred regression :param ref: np array with the reference output :return: scalar metric value

class mse(reader, app_param, eval_param)[source]

Bases: niftynet.evaluation.regression_evaluations.BaseRegressionEvaluation

Computes mean squared error

metric(reg, ref)[source]

Computes a scalar value for the metric :param reg: np.array with inferred regression :param ref: np array with the reference output :return: scalar metric value

class rmse(reader, app_param, eval_param)[source]

Bases: niftynet.evaluation.regression_evaluations.BaseRegressionEvaluation

Computes root mean squared error

metric(reg, ref)[source]

Computes a scalar value for the metric :param reg: np.array with inferred regression :param ref: np array with the reference output :return: scalar metric value

class mae(reader, app_param, eval_param)[source]

Bases: niftynet.evaluation.regression_evaluations.BaseRegressionEvaluation

Computes mean absolute error

metric(reg, ref)[source]

Computes a scalar value for the metric :param reg: np.array with inferred regression :param ref: np array with the reference output :return: scalar metric value