I think this might be related to the use of a long dash (–) instead of a regular dash (-) in the –axis
option. This means the command doesn’t recognise –axis
as an option, but treats it as a regular argument. When that happens, the command sees what it thinks are 5 regular arguments, and therefore assumes arguments 1, 2 & 3 are input images, argument 4 (–axis
) is the operation to be performed, and the last argument (the number 5
) is the output image…
Try using a regular dash rather than a long one. I think these issues tend to happen when commands are copy-pasted from documents that were written using MS Word, since it tends to ‘autocorrect’ dashes into long dashes quite routinely, it’s actually quite difficult to get it to stop…