| Hosted by CoCalc | Download
Kernel: R (R-Project)

Tensorflow in R

version
_ platform x86_64-pc-linux-gnu arch x86_64 os linux-gnu system x86_64, linux-gnu status major 3 minor 4.2 year 2017 month 09 day 28 svn rev 73368 language R version.string R version 3.4.2 (2017-09-28) nickname Short Summer
require(tensorflow) hello <- tf$constant('Hello, TensorFlow!') sess <- tf$Session() sess$run(tf$global_variables_initializer())
Loading required package: tensorflow
sess$run(hello)
'Hello, TensorFlow!'
a <- tf$constant(11.1) b <- tf$constant(3.3) sess$run(a + 2*b)
17.7000007629395
x <- tf$random_normal(shape(10, 10)) y <- sess$run(x) heatmap(as.matrix(y))
Image in a Jupyter notebook