Published unlisted
Edited
Feb 12, 2020
1 fork
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
random_image = () => {
let out_img = tf.tidy(() => {
let rand_vector = tf.randomNormal([1,40])
let out_1 = apply_layer1(rand_vector)
let out_2 = apply_layer2(out_1)
let out_3 = apply_layer3(out_2)
let out_4 = apply_layer4(out_3)
let out_5 = apply_layer5(out_4)
let out_6 = apply_layer6(out_5)
return tf.squeeze(tf.scalar(.5).mul(out_6.add(tf.scalar(1))))
})
let the_img = out_img.arraySync()
tf.dispose(out_img)
return the_img
}
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more