Skip to content

Conversation

@urpetkov-amd
Copy link
Contributor

Fixing dump model ops feature for MIGraphX EP on Windows. The feature wasn't functional because of saving format rules on Windows which are opposite from Linux.

Current state of the feature gives us opportunity to generate and save onnx model after subgraph optimizations before compiling it. On this way we can look how model graph looks like after optimizations and we can use the optimized model.

snnn
snnn previously approved these changes Oct 24, 2025
Copy link
Member

@snnn snnn left a comment

Choose a reason for hiding this comment

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

Yes, all files should be opened in binary mode.

Also, you should check if the file was closed successfully, which is another bug.

@urpetkov-amd
Copy link
Contributor Author

Thanks.
Okay, should we merge this and do that in another PR or add to this one? @snnn

@urpetkov-amd
Copy link
Contributor Author

@snnn

I added changes for this. I added check if file is open, if it's not successfully opened then we can throw an error, otherwise print a log. In this way check for closing is not necessary, it will be closed in the ofstream destructor after leaving the block.

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.

2 participants