TensorBoard without callbacks for Keras docker image in SageMaker

拥有回忆 提交于 2020-05-15 21:19:15

问题


I'm trying to add TensorBoard functionality to this SageMaker example: https://github.com/awslabs/amazon-sagemaker-examples/blob/master/hyperparameter_tuning/keras_bring_your_own/hpo_bring_your_own_keras_container.ipynb

The issue is that SageMaker's Estimator.fit() does not seem to support Keras models compiled with callbacks.

Now from this git issue post it was described that what I need to do for TensorBoard functionality is,

"You need your code inside the container to save checkpoints to S3, and you need to periodically sync your local Tensorboard log directory with your S3 checkpoints."

So to sum it all up, to enable TensorBoard in SageMaker with this custom Keras docker image, it looks like I need a way of periodically uploading a file to an S3 bucket during training without using callbacks. Is this possible to do? I was considering trying to shove this code into a custom loss function, but I'm not sure if this would be the way to go about it. Any help is greatly appreciated!

来源:https://stackoverflow.com/questions/53713660/tensorboard-without-callbacks-for-keras-docker-image-in-sagemaker

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!