Skip to content

[circle-resizer] Add ModelData#15177

Closed
mbencer wants to merge 1 commit intoSamsung:masterfrom
mbencer:mbencer/ModelData
Closed

[circle-resizer] Add ModelData#15177
mbencer wants to merge 1 commit intoSamsung:masterfrom
mbencer:mbencer/ModelData

Conversation

@mbencer
Copy link
Contributor

@mbencer mbencer commented Apr 16, 2025

This commit adds ModelData class to capabilities to load Circle model. The handled model can be accessible both as a buffer and as luci::Module. The main purpose of the class is to keep both representation synchronized.

ONE-DCO-1.0-Signed-off-by: Mateusz Bencer m.bencer@partner.samsung.com

This commit adds ModelData class to capabilities to load Circle model.
The handled model can be accessible both as a buffer and as luci::Module.
The main purpose of the class is to keep both representation synchronized.

ONE-DCO-1.0-Signed-off-by: Mateusz Bencer <m.bencer@partner.samsung.com>
@mbencer mbencer requested review from a team and jinevening April 16, 2025 20:51
/**
* @brief Get the loaded model as the buffer.
*/
std::vector<uint8_t> &buffer();
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Buffer representation of the model (after circle::GetMutableModel) is need to change the inputs shapes like shown in https://github.com/Samsung/ONE/pull/14727/files#diff-89115d8f21eafbf362d2bfbe1ea5677c609681b09b0ad094d6eec8a8e6e5a27eR44

/**
* @brief Get the loaded model as the module.
*/
luci::Module *module();
Copy link
Contributor Author

Choose a reason for hiding this comment

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

module representation is need to run passes related with shape inference on loco::Graph like shown in https://github.com/Samsung/ONE/pull/14727/files#diff-89115d8f21eafbf362d2bfbe1ea5677c609681b09b0ad094d6eec8a8e6e5a27eR82-R85

@jinevening
Copy link
Collaborator

PTAL #14727 (comment)

@mbencer
Copy link
Contributor Author

mbencer commented Apr 17, 2025

No more needed. Chosen approach from #15185

@mbencer mbencer closed this Apr 17, 2025
@mbencer mbencer deleted the mbencer/ModelData branch May 2, 2025 08:12
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