-
Notifications
You must be signed in to change notification settings - Fork 757
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
Refine KerasModelArtifact & its integration test #1295
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1295 +/- ##
==========================================
+ Coverage 66.25% 67.18% +0.92%
==========================================
Files 144 144
Lines 9332 9313 -19
==========================================
+ Hits 6183 6257 +74
+ Misses 3149 3056 -93
Continue to review full report at Codecov.
|
@@ -191,8 +187,11 @@ def load(self, path): | |||
"Failed to import '{}' module when loading saved " | |||
"KerasModelArtifact".format(keras_module_name) | |||
) | |||
|
|||
self.create_session() | |||
else: |
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.
side note: the else
branch was left unhandled for back-ward compatibility reason when this was first created. But I think it is fine raising this exception here now since this was introduced over a year ago.
@bentoml.artifacts( | ||
[ | ||
KerasModelArtifact('model'), | ||
KerasModelArtifact('model2', store_as_json_and_weights=True), |
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.
👍
- name: Run tests with tf2 | ||
run: ./ci/keras_integration_tests.sh | ||
- name: Run tests with tf1 | ||
run: ./ci/keras_with_tf1_integration_tests.sh |
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.
any reason not to put them into two separate tasks?
Fixing the flaky yatai service test. If it continues to cause an issue, I will skip the test(one of the two tests for yatai service) that caused it |
* [CI] integration tests for keras * [FIX] keras artifact * fix for tf1 * test for json n weights * add script for keras with tf1 * add to github action
* [CI] integration tests for keras * [FIX] keras artifact * fix for tf1 * test for json n weights * add script for keras with tf1 * add to github action
Description
Motivation and Context
See linked issues.
How Has This Been Tested?
Added Integration tests for:
tf.keras
with tensorflow 1.14tf.keras
with tensorflow 2.xboth with
store_as_json_and_weights=True
and false.Also tested on gallery/legacy-keras examples.
Types of changes
Component(s) if applicable
Checklist:
./dev/format.sh
and./dev/lint.sh
script have passed(instructions).