Title: af_join vs af_join_many inconsistent empty array behavior[BUG] · Issue #3209 · arrayfire/arrayfire · GitHub
Open Graph Title: af_join vs af_join_many inconsistent empty array behavior[BUG] · Issue #3209 · arrayfire/arrayfire
X Title: af_join vs af_join_many inconsistent empty array behavior[BUG] · Issue #3209 · arrayfire/arrayfire
Description: This is a bug with inconsistent behavior between af_join() and af_join_many() af_join() will retain the original array if the second array is empty af_join_many() will throw an error if it receives an empty array. The docs do currently s...
Open Graph Description: This is a bug with inconsistent behavior between af_join() and af_join_many() af_join() will retain the original array if the second array is empty af_join_many() will throw an error if it receives...
X Description: This is a bug with inconsistent behavior between af_join() and af_join_many() af_join() will retain the original array if the second array is empty af_join_many() will throw an error if it receives...
Opengraph URL: https://github.com/arrayfire/arrayfire/issues/3209
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"af_join vs af_join_many inconsistent empty array behavior[BUG]","articleBody":"This is a bug with inconsistent behavior between __af_join()__ and __af_join_many()__\r\n__af_join()__ will retain the original array if the second array is empty\r\n__af_join_many()__ will throw an error if it receives an empty array. \r\nThe docs do currently specify \"Requires that all dimensions except the join dimension must be the same for all arrays.\" however we can handle this special case and behavior should be consistent between functions.\r\n\r\nExample code snippet for reproducing:\r\n```\r\nauto a = af::array(); // empty\r\nauto b = af::randu(9);\r\n\r\nauto c = af::join(2, a, b); // works\r\n\r\n\r\nstd::vector\u003caf_array\u003e arrs = {a.get(), b.get()};\r\n\r\naf_array out = nullptr;\r\nAF_CHECK(af_join_many(\u0026handle, axis, arrs.size(), arrs.data())); // fails with:\r\n// C++ exception with description \"ArrayFire Exception (Invalid input size:203):\r\n```\r\n","author":{"url":"https://github.com/syurkevi","@type":"Person","name":"syurkevi"},"datePublished":"2022-02-01T21:39:19.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/3209/arrayfire/issues/3209"}
| 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:a41f850e-b0a7-3ac4-ee3e-f496f1b24678 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 8E70:2ECE53:29AEDAA:3945B79:6964E7A5 |
| html-safe-nonce | 96c0fde2932b0f2d31ee1a7f47be29bd3e4adf4f5cd318ece85f315537ddae79 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4RTcwOjJFQ0U1MzoyOUFFREFBOjM5NDVCNzk6Njk2NEU3QTUiLCJ2aXNpdG9yX2lkIjoiNTgzNDAwMjcyMDE1MzIwMDU0OSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | b2f95b8e37716dbaaebf7beb61a2f3d0804c119b142219d455e26531dd6c5185 |
| hovercard-subject-tag | issue:1121226642 |
| 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/3209/issue_layout |
| twitter:image | https://opengraph.githubassets.com/304545949dc1957713e1782d30d8d31f4ad8213b14f7e260bfa169d267b3950c/arrayfire/arrayfire/issues/3209 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/304545949dc1957713e1782d30d8d31f4ad8213b14f7e260bfa169d267b3950c/arrayfire/arrayfire/issues/3209 |
| og:image:alt | This is a bug with inconsistent behavior between af_join() and af_join_many() af_join() will retain the original array if the second array is empty af_join_many() will throw an error if it receives... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | syurkevi |
| hostname | github.com |
| expected-hostname | github.com |
| None | 3c30097417ecb9dfdab6b2e8bc7dc38d73e183d6ad48f94cb69e4a5daa2dbb87 |
| 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 | 69fc54a84c74307369dba42af5401200531d116e |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width