8000 Fixes sub array (opencl) support for confidenceCC by willyborn · Pull Request #3668 · arrayfire/arrayfire · GitHub
[go: up one dir, main page]

Skip to content

Fixes sub array (opencl) support for confidenceCC #3668

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

willyborn
Copy link
Contributor

Using sub-arrays in the confidenceCC function results in undefined behaviour in the opencl backend.

Description

The offsets were not taken into account in the opencl backend:

  • kernel flood_fill
  • seeds array to index conversion

28bd6b0:

  • Adds the the function toTempFormat to the test helpers. This function generates the different temporary array formats (JIT array, SUB-array, Linear array, ...) used by arrayfire.

6016fd8:

  • Adds the offset to the cl code files
  • Copy the seeds (eliminates offset & makes linear) before passing to the index function
  • Adds extra tests for scan.

Is this a new feature or a bug fix?
BUG
Why these changes are necessary.
PREVIOUSLY THE RESULT IS UNDEFINED FOR ABOVE SITUATION
Potential impact on specific hardware, software or backends.
OPENCL only (Unsupported in ONEAPI)
New functions and their functionality.
NO
Can this PR be backported to older versions?
NO
Future changes not implemented in this PR.
NONE, although the function toTempFormat will be used in following PRs.

Changes to Users

Quality improvement.

Checklist

  • Rebased on latest master
  • Code compiles
  • Tests pass
  • Functions added to unified API
  • Functions documented

@christophe-murphy christophe-murphy self-requested a review June 25, 2025 19:32
Removed unnecessary #include
@edwinsolisf edwinsolisf self-requested a review June 27, 2025 19:10
@christophe-murphy christophe-murphy merged commit f01e6fe into arrayfire:master Jun 30, 2025
1 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0