Skip to content

Ricap documentation memcpy changes#537

Merged
r-abishek merged 6 commits intor-abishek:ar/device_memcpy_removalfrom
Srihari-mcw:ricap_documentation_memcpy_changes
Dec 2, 2025
Merged

Ricap documentation memcpy changes#537
r-abishek merged 6 commits intor-abishek:ar/device_memcpy_removalfrom
Srihari-mcw:ricap_documentation_memcpy_changes

Conversation

@Srihari-mcw
Copy link
Copy Markdown
Collaborator

Documentation changes in RICAP and memcpy changes for RICAP

@r-abishek r-abishek requested a review from Copilot December 2, 2025 07:47
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates RICAP (Random Image Crop And Patch) implementation by removing unnecessary hipMemcpy operations and correcting documentation across multiple API header files. The main changes involve directly using the permutationTensor parameter that is already in HIP memory instead of copying it to scratch buffer, along with widespread documentation corrections to accurately reflect memory location requirements for GPU functions.

Key Changes

  • Removed redundant hipMemcpy operations in RICAP GPU implementation and replaced stack-allocated array with hipHostMalloc in test code
  • Renamed permutedIndicesTensor to permutationTensor for consistency across RICAP API
  • Updated documentation for GPU functions to specify tensors are in "pinned/HIP memory" instead of "pinned/HOST memory"

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
utilities/test_suite/HIP/Tensor_image_hip.cpp Replaced stack-allocated array with hipHostMalloc for permutationTensor
src/modules/tensor/rppt_tensor_effects_augmentations.cpp Removed hipMemcpy operations and scratch buffer usage, passing permutationTensor directly to GPU kernels
api/rppt_tensor_effects_augmentations.h Renamed parameter from permutedIndicesTensor to permutationTensor and updated memory location documentation
api/rppt_tensor_geometric_augmentations.h Updated documentation to specify HIP memory for GPU function parameters
api/rppt_tensor_filter_augmentations.h Updated documentation to specify HIP memory for GPU function parameters
api/rppt_tensor_color_augmentations.h Updated documentation to specify HIP memory for GPU function parameters

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +174 to +175
* \param [in] noiseProbailityTensor noiseProbaility values to decide if a destination pixel is a noise-pixel, or equal to source (1D tensor in pinned memory, of size batchSize with 0 <= noiseProbailityTensor[i] <= 1 for each image in batch)
* \param [in] saltProbailityTensor saltProbaility values to decide if a given destination noise-pixel is salt or pepper (1D tensor in pinned memory, of size batchSize with 0 <= saltProbailityTensor[i] <= 1 for each image in batch)
Copy link

Copilot AI Dec 2, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Corrected spelling of 'Probaility' to 'Probability' in parameter names and descriptions.

Copilot uses AI. Check for mistakes.
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

r-abishek and others added 2 commits December 1, 2025 23:51
@r-abishek r-abishek requested a review from Copilot December 2, 2025 07:54
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 6 out of 6 changed files in this pull request and generated 4 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@r-abishek r-abishek added the minor fix Minor implementation fixes label Dec 2, 2025
@r-abishek r-abishek merged commit 25e0d09 into r-abishek:ar/device_memcpy_removal Dec 2, 2025
Srihari-mcw pushed a commit to Srihari-mcw/rpp that referenced this pull request Dec 8, 2025
* Jenkins - CodeCov

* Use rpp codecov token as cred

* Jenkins - Install OpenMP

---------

Co-authored-by: Sam Wu <22262939+samjwu@users.noreply.github.com>
ManasaDattaT pushed a commit to ManasaDattaT/rpp that referenced this pull request Dec 19, 2025
* Jenkins - CodeCov

* Use rpp codecov token as cred

* Jenkins - Install OpenMP

---------

Co-authored-by: Sam Wu <22262939+samjwu@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

minor fix Minor implementation fixes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants