Is it possible to use this package with piecewise functions (e.g., Huber loss)?
@variables a
function huber(a)
δ = 1.0
if abs(a) <= δ
return 0.5*a^2
else
return δ*(abs(a) - 0.5*δ)
end
end
da = huber(a)
This errors on the last line:
TypeError: non-boolean (Operation) used in boolean context
Is it possible to use this package with piecewise functions (e.g., Huber loss)?
This errors on the last line: