APAP
1.Download Source Code
2.进行适当修改,完成版本适配(on 2020a)
开启并行运算的写法的新旧版转换,参考链接。
3.直接运行main.m即可得到拼接效果
Starting parallel pool (parpool) using the 'local' profile ...
Connected to the parallel pool (number of workers: 4).
Which images you want to stitch? [1 for 'temple'] [2 for 'railtracks'] 1
> Stitching 'temple' images
Normalising point distribution...done (0.056263s)
Showing input images...done (2.080158s)
Outlier removal
> Multi-GS (RANSAC) sampling for 100.00 seconds...done (4.580000s)
Showing results of RANSAC...done (3.543883s)
DLT (projective transform) on inliers
> Refining homography (H) using DLT...done (0.028829s)
Canvas size and offset (using global Homography)
> Getting canvas size...done (0.001613s)
> Getting offset...done (0.000259s)
Image stitching with global homography (H) and linear blending
> Warping images by global homography...done (0.381954s)
Homography linear image blending (averaging)...done (5.609294s)
As-Projective-As-Possible Moving DLT on inliers
> Generating mesh for MDLT...done (0.004833s)
Moving DLT main loop...done (3.322271s)
As-Projective-As-Possible Image stitching with Moving DLT and linear blending
> Warping images with Moving DLT...done (0.113754s)
Moving DLT linear image blending (averaging)...done (0.089506s)
> Finished!.
Starting parallel pool (parpool) using the 'local' profile ...
Connected to the parallel pool (number of workers: 4).
Which images you want to stitch? [1 for 'temple'] [2 for 'railtracks'] 2
> Stitching 'railtracks' images
Normalising point distribution...done (0.029726s)
Showing input images...done (0.774497s)
Outlier removal
> Multi-GS (RANSAC) sampling for 100.00 seconds...done (9.840000s)
Showing results of RANSAC...done (7.261263s)
DLT (projective transform) on inliers
> Refining homography (H) using DLT...done (0.082040s)
Canvas size and offset (using global Homography)
> Getting canvas size...done (0.003623s)
> Getting offset...done (0.001474s)
Image stitching with global homography (H) and linear blending
> Warping images by global homography...done (0.364050s)
Homography linear image blending (averaging)...done (0.637137s)
As-Projective-As-Possible Moving DLT on inliers
> Generating mesh for MDLT...done (0.002930s)
Moving DLT main loop...done (1.759561s)
As-Projective-As-Possible Image stitching with Moving DLT and linear blending
> Warping images with Moving DLT...done (0.800325s)
Moving DLT linear image blending (averaging)...done (0.537852s)
> Finished!.
AANAP
1.Download Source Code
2.把上面那些 .m
都放到 mldt
里面,运行 AANAP.m
3.修改图片路径
4.新的Bug呜呜呜…
首先检查图片路径…应该是没有问题的哇…
难道是mex没链接上???试图按照 这里所说的方法,进行链接…但是仿佛出现了XCode SDK版本不适配…
然后我去查了一下各版本对应的XCode SDK…[这里]
在终端中输入 xcodebuild -version
可以查看自己XCode版本信息…
发现如果要的是 MacOSX10.7.sdk 也太难顶了吧…
2->5.算了 不如我们回到实验室的Win10上跑吧…
按照上述所说路径解压好下载的图像数据,就能够直接跑了呢hhh
虽然也出现了一些需要调整的问题,但是在上一篇记录里都解决了哦~
我们来看看效果…
网格扭曲可视化:
另外,有一点点小报错:
[参考] 据说这个是因为 inv是对矩阵求逆,而对于不是可逆矩阵的矩阵求逆就会出错,pinv
就是对不是可逆矩阵
的矩阵求伪逆
。