-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
tensorflow
: add tf.train.CheckpointOptions
and other tf.train
members.
#11327
tensorflow
: add tf.train.CheckpointOptions
and other tf.train
members.
#11327
Conversation
This comment has been minimized.
This comment has been minimized.
4d5f801
to
6fed7b9
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
002b143
to
789b115
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
c7ad7f2
to
a477d9d
Compare
a477d9d
to
0f7548c
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
@hmc-cs-mdrissi I don't know how to fix the metaclass issue that causes the CI to fail, since |
If you re-export protobuf types from mypy-protobuf generated files that should fix your stubtest metaclass issues. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
8ccd9f4
to
a2b8165
Compare
This comment has been minimized.
This comment has been minimized.
a2b8165
to
d29e821
Compare
This comment has been minimized.
This comment has been minimized.
d29e821
to
794e769
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
from _typeshed import Incomplete | ||
|
||
# @dataclasses.dataclass(frozen=True) | ||
# class ShardableTensor: |
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.
For this one I am mainly waiting on either commented out stubs to be finished and not comment or from them to be removed and left for future pr.
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 class was added to the tensorflow repo last month, so it's not in the doc yet (nor in the latest runtime version). I realized this afterwards and left them comment out to be able to easily add them in the future (I'm assuming the classes will make their way into the next version of tensorflow).
Should I add a comment explaining this, or is it better to remove them for now and add them in a future PR once they have been added to a released version of tensorflow ?
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.
I recommend removing them. After next tensorflow release they can be added then.
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.
Done in 080b155
e8541b9
to
825e16c
Compare
825e16c
to
5532157
Compare
This comment has been minimized.
This comment has been minimized.
class CheckpointOptions: | ||
experimental_io_device: None | str | ||
experimental_enable_async_checkpoint: bool | ||
# experimental_write_callbacks: None | list[Callable[[str], Any] | Callable[[], Any]] |
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.
Are these also due to be added in a future release? I'm OK with leaving them commented out for now, but please put a comment somewhere in the stub about it, so we don't forget why there is this commented out code here.
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.
Yes, looking at the 2.12 doc they are not present.
One of them is already in 2.15, two are not present in a release yet but are present in the tensorflow code.
I've removed the ones not present in 2.15, and added comments for the rest in 2ad4be9.
According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉 |
This adds
tf.train.CheckpointOptions
and the othertf.train
members from here.@hmc-cs-mdrissi If you have time to review it.