pysolvegn.get_rho_function_by_name#

get_rho_function_by_name(name)[source]#

Get a predefined rho function by name.

Parameters:

name (str) – The name of the rho function. Must be one of "linear", "soft_l1", "cauchy", "arctan", "huber" or "tukey".

Returns:

rho_func – A function that takes the squared residuals \(x = \|R\|^2\) and returns the cost function value, its first derivative, and its second derivative.

Return type:

Callable