Skip to content
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

Add mode test #215

Merged
merged 3 commits into from
Apr 30, 2024
Merged

Add mode test #215

merged 3 commits into from
Apr 30, 2024

Conversation

CongMa13
Copy link
Collaborator

@CongMa13 CongMa13 commented Apr 19, 2024

Add support for any modes of tensors

For example, modes could be

A: K5K3M0M5K4K1M3K2M1K0M4M2 
B: M4M0M3M5K4M2K2K3M1K5K1K0 
C: K1K4K3M2M4K5M5M0K0M1M3K2

One change to support the mode unit test is sequence test parameters.

Combined test parameter is the only type supported before. But in mode test we cannot combine lengths with modes.

for example, length [1, 2], [1, 2, 3] cannot combine with modes [0, 1], [0, 1, 2]

So added support to sequence test parameters.

Example: test.yaml

Param1: 2.1
Param2: ALGO_DEFAULT
Param3: HIP_C_32F 
Param4:
  - 1
  - 2
  - 3
 Param5:
  - a
  - b
  - c

The test params are

2.1, ALGO_DEFAULT, HIP_C_32F, 1, a
2.1, ALGO_DEFAULT, HIP_C_32F, 2, b
2.1, ALGO_DEFAULT, HIP_C_32F, 3, c

image

@CongMa13 CongMa13 marked this pull request as ready for review April 22, 2024 20:35
cgmillette
cgmillette previously approved these changes Apr 24, 2024
Copy link
Collaborator

@cgmillette cgmillette left a comment

Choose a reason for hiding this comment

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

Looks good - just maybe needs some more description on the normalization procedure and why that's needed 👍🏼

mkarunan
mkarunan previously approved these changes Apr 25, 2024
Copy link
Contributor

@mkarunan mkarunan left a comment

Choose a reason for hiding this comment

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

Looks great

@CongMa13 CongMa13 dismissed stale reviews from mkarunan and cgmillette via 9381cc8 April 25, 2024 17:03
…e test

- Remove elementSpaceFromLengthsAndStrides()

    elementSpaceFromLengthsAndStrides has the same feature as
    elementsFromLengths

- Test modes of input and output tensor in random orders
It does not affect the feature to set the padding stride to 1.
But it is easier to understand the algorithm to set the padding stride
to the previous valid strid.
@CongMa13 CongMa13 force-pushed the fix_yaml branch 2 times, most recently from 194e42e to 2a0ee73 Compare April 30, 2024 15:08
@CongMa13 CongMa13 merged commit a2c3e10 into ROCm:develop Apr 30, 2024
2 of 7 checks passed
@CongMa13 CongMa13 deleted the fix_yaml branch April 30, 2024 15:20
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