Skip to content

[shape_infer] Can we use explicit(full) template specialization for shape_infer() on static/partial shapes? #2

Answered by jane-intel
usstq asked this question in Q&A
Discussion options

You must be logged in to vote

I would suggest to try minimize specialized code

Say, we have three specific lines of code for PartialShape and for StaticShape we should raise an exception there -- then lets create template helper function
template
helper (const T& in, T& out) {
// code for StaticShape
}

template <>
helperov::PartialShape(const ov::PartialShape& in, ov::PartialShape& out) {
// code specific to PartialShape
}

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@usstq
Comment options

usstq Oct 28, 2021
Maintainer Author

Answer selected by usstq
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants