-
Notifications
You must be signed in to change notification settings - Fork 3.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Frontend][Tensorflow] SelectV2 and BroadcastArgs op support for tf2 models #7901
Conversation
out.appendleft(s1[s1_size - i]) | ||
if s1_size < s0_size: | ||
for i in range(s1_size + 1, s0_size + 1): | ||
out.appendleft(s0[s0_size - i]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it better to use itertools.zip_longest() on the reversed array instead of running three separate loops? Might be helpful to have fill_values set at 1 to avoid handling None values.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will require atleast two list inversions (both the inputs as we have to iterate in reverse to verify broadcasting rules). Fill values will only make sense if I use a zip. It is only two loops (one of last two will fail) and merging them to one will give marginal optimization.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please revert the change of updating submodules.
Also cc @yongwww @kevinthesun @zhiics
89ac729
to
013590d
Compare
013590d
to
3df4763
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Thanks @srinidhigoud @rohanmukh |
Adding support in tf parser for new ops SelectV2 and BroadcastArgs introduced by tf2. This is focused on compiling and running the tf2 version of the object detection models such as faster rcnn model. Since both the inputs to BroadcastArgs were constant for every instance of the op in the model there was no need to write a relay op.