Error in FineRegistration with warping option ON
When using the application
FineRegistration with the warping option, for example with the command line
otbcli_FineRegistration -ref StereoFixed.png -sec StereoMoving.png -out FineRegistration.tif -erx 2 -ery 2 -mrx 3 -mry 3 -w StereoFixed.png -wo warped.tif
and if the output disparity map file (here FineRegistration.tif) doesn't exist before calling the application, the application produces the error : "(FATAL): Cannot open image FineRegistration.tif. The file does not exist."
The application has two distinct pipelines with two output image writers :
- The first pipeline uses the input image to produce the disparity map
- The second pipeline takes the disparity map as input and computes the warped image.
This could work, the first pipeline executes and writes the input for the second pipeline, and then the second pipeline executes. But in the application class workflow, there is a call on
UpdateOutputParameters() on all the writers before actually writing the data. This means that the reader of the second pipeline checks if the disparity map file exists before it has been created by the first pipeline, thus producing the error.
All OS, OTB 6.6