Skip to content

Conversation

@wcy123
Copy link
Contributor

@wcy123 wcy123 commented Aug 1, 2025

Description

It is related to #25320 #23979. Enable tensor raw data sharing for externalized tensor proto with kTensorProtoMemoryAddressTag

Motivation and Context

With #25320 #23979, all initialized tensor protos are associated with OrtValue, VitisiAI EP need to adapt to this change.

@HectorSVC
Copy link
Contributor

/azp run Linux QNN CI Pipeline,Win_TRT_Minimal_CUDA_Test_CI,Windows ARM64 QNN CI Pipeline,Windows GPU Doc Gen CI Pipeline,Windows x64 QNN CI Pipeline

@azure-pipelines
Copy link

Azure Pipelines successfully started running 5 pipeline(s).

@HectorSVC HectorSVC added the ep:VitisAI issues related to Vitis AI execution provider label Aug 1, 2025
@jywu-msft jywu-msft requested a review from yuslepukhin August 1, 2025 15:28
@adrianlizarraga
Copy link
Contributor

Hi @wcy123,
Thank you for tracking this down. Could you please try evaluating this branch to see if it resolves the issue: #25626

We would like to avoid exposing the kTensorProtoMemoryAddressTag functionality to EPs as that should be internal to onnxruntime. Thank you.

@jywu-msft
Copy link
Member

Hi @wcy123, Thank you for tracking this down. Could you please try evaluating this branch to see if it resolves the issue: #25626

We would like to avoid exposing the kTensorProtoMemoryAddressTag functionality to EPs as that should be internal to onnxruntime. Thank you.

yes. let's not merge this PR. pls validate the general fix works for you. thank you!

@wcy123
Copy link
Contributor Author

wcy123 commented Aug 5, 2025

Hi @wcy123, Thank you for tracking this down. Could you please try evaluating this branch to see if it resolves the issue: #25626
We would like to avoid exposing the kTensorProtoMemoryAddressTag functionality to EPs as that should be internal to onnxruntime. Thank you.

yes. let's not merge this PR. pls validate the general fix works for you. thank you!

Based on our comprehensive local testing, we observed that while PR #25626 successfully addresses issues for some models, several others continue to experience the same problems. Therefore, this current PR remains necessary to fully resolve the outstanding issues.

cc Guggilla, Nithin Kumar Bader Adam.

@HectorSVC
Copy link
Contributor

/azp run Linux QNN CI Pipeline,Win_TRT_Minimal_CUDA_Test_CI,Windows ARM64 QNN CI Pipeline,Windows GPU Doc Gen CI Pipeline,Windows x64 QNN CI Pipeline

@azure-pipelines
Copy link

Azure Pipelines successfully started running 5 pipeline(s).

@HectorSVC
Copy link
Contributor

There's another fix in progress: #25652

@HectorSVC HectorSVC closed this Aug 5, 2025
@HectorSVC HectorSVC reopened this Aug 5, 2025
@yuslepukhin
Copy link
Member

yuslepukhin commented Aug 8, 2025

if (tensor_proto->data_location() == ONNX_NAMESPACE::TensorProto_DataLocation::TensorProto_DataLocation_EXTERNAL) {

utils::HasExternalData() or utils::HasExternalDataInMemory()

This is available from core/framework/tensorprotoutil.h

Creating and reading external data is encoded in ExternalData class.

The same utils have Unpack() methods that handle all kinds of data within TensorProto


Refers to: onnxruntime/core/providers/vitisai/imp/tensor_proto.cc:18 in 1109d03. [](commit_id = 1109d03, deletion_comment = False)

@yuslepukhin
Copy link
Member

/azp run Test Linux CUDA x64 Release,Test Linux TensorRT x64 Release,Windows GPU Doc Gen CI Pipeline, windows_x64_debug/build_x64_debug (pull_request),web_Debug/build_onnxruntime_web, web_Debug / build_onnxruntime_web

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Copy link
Member

@yuslepukhin yuslepukhin left a comment

Choose a reason for hiding this comment

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

:shipit:

@adrianlizarraga adrianlizarraga merged commit bfd7f97 into microsoft:main Aug 8, 2025
217 checks passed
adrianlizarraga pushed a commit that referenced this pull request Aug 9, 2025
### Description

It is related to #25320 #23979. Enable tensor raw data sharing for
externalized tensor proto with kTensorProtoMemoryAddressTag

### Motivation and Context

With #25320 #23979, all initialized tensor protos are associated with
OrtValue, VitisiAI EP need to adapt to this change.

Co-authored-by: mingyue <[email protected]>
jywu-msft pushed a commit that referenced this pull request Aug 9, 2025
### Description
Cherry-pick the following PRs into `rel-1.23.0`:
- #25629
- #25583



### Motivation and Context
<!-- - Why is this change required? What problem does it solve?
- If it fixes an open issue, please link to the issue here. -->

---------

Co-authored-by: Chunye Wang@AMD <[email protected]>
Co-authored-by: mingyue <[email protected]>
Co-authored-by: Artur Wojcik <[email protected]>
Co-authored-by: urpetkov-amd <[email protected]>
Co-authored-by: Ted Themistokleous <[email protected]>
Co-authored-by: Ted Themistokleous <[email protected]>
Co-authored-by: Scott McKay <[email protected]>
sanketkaleoss pushed a commit to sanketkaleoss/onnxruntime that referenced this pull request Aug 11, 2025
### Description

It is related to microsoft#25320 microsoft#23979. Enable tensor raw data sharing for
externalized tensor proto with kTensorProtoMemoryAddressTag

### Motivation and Context

With microsoft#25320 microsoft#23979, all initialized tensor protos are associated with
OrtValue, VitisiAI EP need to adapt to this change.

Co-authored-by: mingyue <[email protected]>
gedoensmax pushed a commit to gedoensmax/onnxruntime that referenced this pull request Sep 2, 2025
### Description

It is related to microsoft#25320 microsoft#23979. Enable tensor raw data sharing for
externalized tensor proto with kTensorProtoMemoryAddressTag

### Motivation and Context

With microsoft#25320 microsoft#23979, all initialized tensor protos are associated with
OrtValue, VitisiAI EP need to adapt to this change.

Co-authored-by: mingyue <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ep:VitisAI issues related to Vitis AI execution provider

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants