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

String Tensor SplitToSequence fix #19942

Merged
merged 1 commit into from
Mar 20, 2024

Conversation

Craigacp
Copy link
Contributor

Description

The SplitToSequence refactor added a special case for element_size when it's a string, but this stops the computation of the A offset on line 510 from advancing as the offset is zero. So it copies the same string into each sequence element. This PR removes that check and adds a test for the string split behaviour.

I'm not sure why the special case on line 456 was added in the original PR (#18594), but all the tests pass in the new PR so presumably it isn't necessary.

Motivation and Context

SplitToSequence didn't work on string tensors, fixes #19726.

cc @pranavsharma

@justinchuby justinchuby added the core runtime issues related to core runtime label Mar 19, 2024
@justinchuby
Copy link
Contributor

/azp run Linux CPU CI Pipeline,Linux CPU Minimal Build E2E CI Pipeline,Linux GPU CI Pipeline,Linux GPU TensorRT CI Pipeline,Linux OpenVINO CI Pipeline,Linux QNN CI Pipeline,MacOS CI Pipeline,ONNX Runtime Web CI Pipeline,Windows ARM64 QNN CI Pipeline

@justinchuby
Copy link
Contributor

/azp run Windows CPU CI Pipeline,Windows GPU CI Pipeline,Windows GPU TensorRT CI Pipeline,Windows x64 QNN CI Pipeline,orttraining-linux-ci-pipeline,orttraining-linux-gpu-ci-pipeline,orttraining-ortmodule-distributed,onnxruntime-binary-size-checks-ci-pipeline

Copy link

Azure Pipelines successfully started running 8 pipeline(s).

Copy link

Azure Pipelines successfully started running 9 pipeline(s).

@Craigacp
Copy link
Contributor Author

The Windows GPU TensorRT failure says that it couldn't find a CUDA device in tests other than the one I added, and they don't appear at first glance to use SplitToSequence either. Maybe it hit some dodgy hardware?

@tianleiwu
Copy link
Contributor

/azp run ONNX Runtime Web CI Pipeline,orttraining-amd-gpu-ci-pipeline,Big Models,Android CI Pipeline,iOS CI Pipeline,ONNX Runtime React Native CI Pipeline

Copy link

Azure Pipelines successfully started running 6 pipeline(s).

@baijumeswani baijumeswani merged commit 19ff4a6 into microsoft:main Mar 20, 2024
81 of 82 checks passed
@Craigacp Craigacp deleted the split-to-sequence-fix branch March 20, 2024 17:56
YUNQIUGUO pushed a commit that referenced this pull request Mar 21, 2024
TedThemistokleous pushed a commit to TedThemistokleous/onnxruntime that referenced this pull request May 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core runtime issues related to core runtime
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SplitToSequence op with string tensor inputs behaves incorrectly in ONNX Runtime 1.17.1
5 participants