Open
Description
An error is produced when view_savedmodel
is ran. The problem is with the line within the function code tf$python$platform$gfile
. I think it is due to gfile
being deprecated in the new TensorFlow release. For example:
x <- tf$Variable(10)
checkpoint <- tf$train$Checkpoint(x = x)
tf$saved_model$save(checkpoint, "./models/")
view_savedmodel("./models/")
Error in py_get_attr_impl(x, name, silent) :
AttributeError: 'module' object has no attribute 'gfile'
I am using version 2.0.0 of {tensorflow} with version 2.2.0 of
My session information is:
R version 3.6.3 (2020-02-29)
Platform: x86_64-redhat-linux-gnu (64-bit)
Running under: CentOS Linux 7 (Core)
Matrix products: default
BLAS: /usr/lib64/libblas.so.3.4.2
LAPACK: /opt/mango/R/3.6.3/lib/R/lib/libRlapack.so
locale:
[1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C
[3] LC_TIME=en_US.UTF-8 LC_COLLATE=en_US.UTF-8
[5] LC_MONETARY=en_US.UTF-8 LC_MESSAGES=en_US.UTF-8
[7] LC_PAPER=en_US.UTF-8 LC_NAME=C
[9] LC_ADDRESS=C LC_TELEPHONE=C
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] tensorflow_2.0.0 silver_0.2.7.9001 testthat_2.3.2
loaded via a namespace (and not attached):
[1] Rcpp_1.0.3 compiler_3.6.3 pillar_1.4.3 git2r_0.26.1
[5] base64enc_0.1-3 tools_3.6.3 jsonlite_1.6.1 praise_1.0.0
[9] tibble_2.1.3 pkgconfig_2.0.3 rlang_0.4.5 cli_2.0.2
[13] rstudioapi_0.11 curl_4.3 withr_2.1.2 stringr_1.4.0
[17] dplyr_0.8.5 httr_1.4.1 vctrs_0.2.3 desc_1.2.0
[21] fs_1.3.2 rappdirs_0.3.1 rprojroot_1.3-2 tidyselect_1.0.0
[25] reticulate_1.14 glue_1.3.1 R6_2.4.1 fansi_0.4.1
[29] vapidr_0.0.4 purrr_0.3.3 logger_0.1 magrittr_1.5
[33] whisker_0.4 backports_1.1.5 tfruns_1.4 assertthat_0.2.1
[37] stringi_1.4.6 crayon_1.3.4