Skip to content

Support provide ORT session options in onnx_graphsurgeon fold_constants#4575

Open
OYCN wants to merge 1 commit intoNVIDIA:mainfrom
OYCN:support-custom-ort-opt
Open

Support provide ORT session options in onnx_graphsurgeon fold_constants#4575
OYCN wants to merge 1 commit intoNVIDIA:mainfrom
OYCN:support-custom-ort-opt

Conversation

@OYCN
Copy link
Copy Markdown

@OYCN OYCN commented Sep 10, 2025

Closes #4574

User can provide the custom operator libs by

so = ort.SessionOptions()
so.register_custom_ops_library(...)
g.fold_constants(..., ort_session_options=so)

Passing some options to avoid some ORT bug

so = ort.SessionOptions()
so.graph_optimization_level = ort.GraphOptimizationLevel.ORT_DISABLE_ALL
g.fold_constants(..., ort_session_options=so)

@OYCN OYCN requested a review from a team as a code owner September 10, 2025 06:00
@OYCN OYCN changed the title Support provide ORT session options in gs fold_constants Support provide ORT session options in onnx_graphsurgeon fold_constants Sep 10, 2025
@OYCN OYCN force-pushed the support-custom-ort-opt branch from 6ecde05 to af3acdc Compare April 3, 2026 10:04
Signed-off-by: opluss <opluss@qq.com>
@OYCN OYCN force-pushed the support-custom-ort-opt branch from af3acdc to fff50b8 Compare April 3, 2026 10:06
@OYCN
Copy link
Copy Markdown
Author

OYCN commented Apr 3, 2026

Hi @kevinch-nv @akhilg-nv, Can you help to review this PR ?

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.

Need to support user provide ORT session options in onnx_graphsurgeon fold_constants

1 participant