Title: homography() results depend on order of points · Issue #1264 · arrayfire/arrayfire · GitHub
Open Graph Title: homography() results depend on order of points · Issue #1264 · arrayfire/arrayfire
X Title: homography() results depend on order of points · Issue #1264 · arrayfire/arrayfire
Description: Below is my post from the Google groups page with details on this issue. It seems that the results of the homography() function depend on the order of the X and Y features passed in. This should not be the case. -Eric I'm trying to use h...
Open Graph Description: Below is my post from the Google groups page with details on this issue. It seems that the results of the homography() function depend on the order of the X and Y features passed in. This should no...
X Description: Below is my post from the Google groups page with details on this issue. It seems that the results of the homography() function depend on the order of the X and Y features passed in. This should no...
Opengraph URL: https://github.com/arrayfire/arrayfire/issues/1264
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"homography() results depend on order of points","articleBody":"Below is my post from the Google groups page with details on this issue. It seems that the results of the homography() function depend on the order of the X and Y features passed in. This should not be the case.\n\n-Eric\n\nI'm trying to use harris() and homography() to do image registration. I start with an array called imgBase which is a 150x150 array of floats on the range [0,255]. I can plot this in ArrayFire and it looks correct (assuming I normalize it to the range [0,1]). The image is a portion of a satellite image (part of Matlab's westconcordaerial.png) and has some nice corner features from buildings, roads, etc.\n\nTo try to understand what is going on, I've done the following:\n\naf::features featuresBase = af::harris(imgBase);\naf::features featuresReg = af::harris(imgBase);\naf::homography(H_ctr, inliers, featuresReg.getX(), featuresReg.getY(), featuresBase.getX(), featuresBase.getY(), AF_HOMOGRAPHY_RANSAC, 5.0f, 1000, f32);\n\nThe featuresBase and featuresReg objects each contain 434 features. These features are identical except that they are ordered differently. I do not know why they would be ordered differently as they are passed the same image. I've checked this property of the features by exporting them to Matlab. When plotted on a 2D plot they overlay exactly. However, element-wise differences in X or Y coordinates are not identically zero and I can visually inspect that the vectors are not equal.\n\nThe homography() call then reports only 10 inliers. It returns the homography\n\n```\n0.1973 0.0222 0.0010\n```\n\n -0.0693 -0.0947 0.0009\n -20.4484 -5.5688 -0.3293\n\nwhich makes little sense. Does the ordering of the X, Y points affect the RANSAC result? It seems like it should not.\n\nIf I change the homography() function call to:\n\naf::homography(H_ctr, inliers, featuresBase.getX(), featuresBase.getY(), featuresBase.getX(), featuresBase.getY(), AF_HOMOGRAPHY_RANSAC, 5.0f, 1000, f32);\n\nthe function behaves as expected. It returns 434 inliers and a homography array of\n\n```\n0.1970 -0.0000 -0.0000\n0.0000 0.1970 0.0000\n```\n\n -0.0000 -0.0000 0.1970\n\nI expected this to be the 3x3 identity matrix, but I assume I should normalize by the lower-right-most element.\n","author":{"url":"https://github.com/shie0041","@type":"Person","name":"shie0041"},"datePublished":"2016-02-04T18:16:45.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":4},"url":"https://github.com/1264/arrayfire/issues/1264"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:22e159cf-9aba-54ab-ae23-a4d5c20b2c6b |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | C54A:DC558:EB9E43:13A7F31:6969A078 |
| html-safe-nonce | 61470e2721f29f572bc031c7df84706b62f50c9fd1359b482ba9f544c08213cf |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDNTRBOkRDNTU4OkVCOUU0MzoxM0E3RjMxOjY5NjlBMDc4IiwidmlzaXRvcl9pZCI6IjI3MTEyMzMzMjE4MDUzODk5NDQiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 2ce9ad1860c2f7d45def745e6776de23a58b04f625444bd7909b0b1540485307 |
| hovercard-subject-tag | issue:131430549 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/arrayfire/arrayfire/1264/issue_layout |
| twitter:image | https://opengraph.githubassets.com/6cbafc6f77362bcfa76c4437d36a3b6ee04734f036be9bb1ad6cd1969cd4ad56/arrayfire/arrayfire/issues/1264 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/6cbafc6f77362bcfa76c4437d36a3b6ee04734f036be9bb1ad6cd1969cd4ad56/arrayfire/arrayfire/issues/1264 |
| og:image:alt | Below is my post from the Google groups page with details on this issue. It seems that the results of the homography() function depend on the order of the X and Y features passed in. This should no... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | shie0041 |
| hostname | github.com |
| expected-hostname | github.com |
| None | 24c4c97a2d520cb286b35e1a4c22d7a4df3c26a2fa28dd7cdf0e65db327b4de7 |
| turbo-cache-control | no-preview |
| go-import | github.com/arrayfire/arrayfire git https://github.com/arrayfire/arrayfire.git |
| octolytics-dimension-user_id | 5395442 |
| octolytics-dimension-user_login | arrayfire |
| octolytics-dimension-repository_id | 25889802 |
| octolytics-dimension-repository_nwo | arrayfire/arrayfire |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 25889802 |
| octolytics-dimension-repository_network_root_nwo | arrayfire/arrayfire |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 124667f43168afb6c9c03b7c02eb5b1d2e1be3d9 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width