Skip to content

[TFLite] Add support to int16 data type in TFLite frontend#10915

Merged
lhutton1 merged 2 commits into
apache:mainfrom
leandron:int16-tflite
May 18, 2022
Merged

[TFLite] Add support to int16 data type in TFLite frontend#10915
lhutton1 merged 2 commits into
apache:mainfrom
leandron:int16-tflite

Conversation

@leandron

@leandron leandron commented Apr 6, 2022

Copy link
Copy Markdown
Contributor

Add support for int16 data type and int64 biases/accumulators in the TFLite frontend. Adjusts TFLite tests to cover int16 convolutions and element-wise; Fixes a minor typo negtive->negative in the element-wise tests.

cc @lhutton1 @NicolaLancellotti @ekalda @masahi for reviews

@github-actions github-actions Bot requested a review from masahi April 6, 2022 14:47

@lhutton1 lhutton1 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks @leandron, looks good to me!

Comment thread tests/python/frontend/tflite/test_forward.py Outdated

@NicolaLancellotti NicolaLancellotti left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@ekalda ekalda left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good, thanks for adding the int16 support @leandron! Do you know if there any int16 models around by any chance we could test?

Comment thread src/relay/qnn/op/convolution.cc
@leandron leandron force-pushed the int16-tflite branch 9 times, most recently from d1d1311 to 8940807 Compare May 6, 2022 13:16
Add support for int16 data type and int64 biases/accumulators in
the TFLite frontend.

Adjusts TFLite tests to cover int16 convolutions and element-wise;
Fixes a minor typo negtive->negative in the element-wise tests.

@ekalda ekalda left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good to me, few nits... Great job for getting int16 mobilenet and conv2d tests running, I think it's a really good improvement to our frontend infra!

Comment thread src/relay/qnn/op/convolution.cc Outdated
Comment thread src/relay/qnn/op/convolution.cc
Comment thread tests/python/frontend/tflite/test_forward.py Outdated

@ekalda ekalda left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks for all the work on this @leandron, LGTM! :)

Comment thread src/relay/qnn/op/convolution.cc

@lhutton1 lhutton1 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks @leandron LGTM! Just a couple of comments about testing but feel free to take in a follow up

Comment thread tests/python/frontend/tflite/test_forward.py
Comment thread tests/python/frontend/tflite/test_forward.py
Comment thread tests/python/frontend/tflite/test_forward.py
Co-authored-by: Elen Kalda <elen.kalda@arm.com>
@lhutton1 lhutton1 merged commit f88a10f into apache:main May 18, 2022
@lhutton1

Copy link
Copy Markdown
Contributor

Thanks @leandron, @ekalda!

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.

4 participants