";
foreach ($row as $cell) {
$output .= "";
if ($cell === false) {
$output .= "false";
}
else {
$output .= round($cell, 3);
}
$output .= " | ";
}
$output .= "
";
}
$output .= "";
return $output;
}
$matrix = [
[-1, 0, -1],
[ 0, 4, 0],
[-1, 0, -1],
];
$kernel = \ImagickKernel::fromMatrix($matrix);
$kernel->scale(1, \Imagick::NORMALIZE_KERNEL_VALUE);
$output = "Before adding unity kernel: