Skip to content

Conversation

@yifei410
Copy link
Contributor

Description

Add new API to VitisAI to save graph as a string

Motivation and Context

to support in-memory flow

@yifei410
Copy link
Contributor Author

@microsoft-github-policy-service agree company="AMD"

@HectorSVC HectorSVC requested a review from Copilot July 30, 2025 19:54
@HectorSVC HectorSVC added the ep:VitisAI issues related to Vitis AI execution provider label Jul 30, 2025
Copy link
Contributor

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 adds a new API function to VitisAI that allows saving a graph as a string instead of to a file, supporting in-memory workflows. The change increments the API major version and implements the string serialization functionality.

  • Added graph_save_string function that serializes a graph to a string using protobuf
  • Incremented VAIP_ORT_API_MAJOR version from 17 to 18 to reflect the API addition
  • Integrated the new function into the global API structure

Reviewed Changes

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

File Description
vaip_ort_api.h Increments API version and adds function pointer for graph_save_string
graph.h Declares the new graph_save_string function
graph.cc Implements graph_save_string with protobuf serialization logic
global_api.cc Registers the new function in the global API structure

@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

/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

/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 merged commit 866c7e3 into microsoft:main Jul 31, 2025
86 of 90 checks passed
sanketkaleoss pushed a commit to sanketkaleoss/onnxruntime that referenced this pull request Aug 11, 2025
…#25602)

### Description
Add new API to VitisAI to save graph as a string

### Motivation and Context
to support in-memory flow

---------

Co-authored-by: yifei <[email protected]>
apsonawane pushed a commit that referenced this pull request Oct 17, 2025
### Description
Add new API to VitisAI to save graph as a string

### Motivation and Context
to support in-memory flow

---------

Co-authored-by: yifei <[email protected]>
apsonawane pushed a commit that referenced this pull request Oct 20, 2025
### Description
Add new API to VitisAI to save graph as a string

### Motivation and Context
to support in-memory flow

---------

Co-authored-by: yifei <[email protected]>
apsonawane added a commit that referenced this pull request Oct 21, 2025
Adds the following commits to the release-1.23.2 branch for ORT 1.23.2:

- [TensorRT] Fix DDS output bug during engine update
  - PR: #26272
  - commit id: 00e85dd
- Fix shape inference failure with in-memory external data
   - PR: #26263
   - commit id: d955476
- [CUDA] replace 90a-virtual by 90-virtual for forward compatible 
  - PR: #26230
  - commit id: b58911f
- [QNN-EP] Fix logic flow bug
  - PR: #26148
  - commit id: b282379
- Internal Dupe of #25255 - [MLAS] Optimize MlasConv using thread
partition opt
  - PR: #26103
  - commit id: 7362518
- Update qMoE spec to support block quantization
  - PR: #25641
  - commit id: 7a8ffa8
- [VitisAI] add new api to VitisAI to save graph as a string
  - PR: #25602
  - commit id: 3361d72
- [[Build] Lock torch, onnxscript and onnx-ir versions to latest]
  - PR: #26315
  - commit id: ea69c4d

---------

Co-authored-by: Hariharan Seshadri <[email protected]>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Edward Chen <[email protected]>
Co-authored-by: Yateng Hong <[email protected]>
Co-authored-by: Changming Sun <[email protected]>
Co-authored-by: Dmitri Smirnov <[email protected]>
Co-authored-by: Tianlei Wu <[email protected]>
Co-authored-by: quic-calvnguy <[email protected]>
Co-authored-by: quic_calvnguy <quic_calvnguy@quic_inc.com>
Co-authored-by: yifei410 <[email protected]>
Co-authored-by: yifei <[email protected]>
@apsonawane
Copy link
Contributor

Cherry-picked for 1.23.2. Removing the release tag and adding cherry-pick tag

@apsonawane apsonawane added cherry-picked Cherry-picked for a cherrypicks branch and removed release:1.23.2 labels Oct 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cherry-picked Cherry-picked for a cherrypicks branch ep:VitisAI issues related to Vitis AI execution provider

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants