Fixing data type from min_mae function
and fixing calculation

Signed-off-by: Renato Stoffalette Joao <renatosjoao@gmail.com>