Spaces:
Runtime error
Runtime error
Wooooo smaller repo!
Browse files- app.py +3 -24
- data/train_test_split_data.npz +0 -0
app.py
CHANGED
|
@@ -5,30 +5,9 @@ import tensorflow
|
|
| 5 |
import math
|
| 6 |
from tensorflow.python.framework.ops import disable_eager_execution
|
| 7 |
|
| 8 |
-
#
|
| 9 |
disable_eager_execution()
|
| 10 |
|
| 11 |
-
# # Load the training and testing data
|
| 12 |
-
# load_data = numpy.load('data/train_test_split_data.npz') # Data saved by the VAE
|
| 13 |
-
#
|
| 14 |
-
# # Convert Data to Tuples and Assign to respective variables
|
| 15 |
-
# box_matrix_train, box_density_train, additional_pixels_train, box_shape_train = tuple(
|
| 16 |
-
# load_data['box_matrix_train']), tuple(load_data['box_density_train']), tuple(
|
| 17 |
-
# load_data['additional_pixels_train']), tuple(load_data['box_shape_train'])
|
| 18 |
-
# box_matrix_test, box_density_test, additional_pixels_test, box_shape_test = tuple(load_data['box_matrix_test']), tuple(
|
| 19 |
-
# load_data['box_density_test']), tuple(load_data['additional_pixels_test']), tuple(load_data['box_shape_test'])
|
| 20 |
-
# testX = box_matrix_test # Shows the relationship to the MNIST Dataset vs the Shape Dataset
|
| 21 |
-
# image_size = numpy.shape(testX)[-1] # Determines the size of the images
|
| 22 |
-
# test_data = numpy.reshape(testX, (len(testX), image_size, image_size, 1))
|
| 23 |
-
|
| 24 |
-
# Creates tuples that contain all of the data generated
|
| 25 |
-
# allX = numpy.append(box_matrix_train, box_matrix_test, axis=0)
|
| 26 |
-
# all_box_density = numpy.append(box_density_train, box_density_test, axis=0)
|
| 27 |
-
# all_additional_pixels = numpy.append(additional_pixels_train, additional_pixels_test, axis=0)
|
| 28 |
-
# all_box_shape = numpy.append(box_shape_train, box_shape_test, axis=0)
|
| 29 |
-
# all_data = numpy.reshape(allX, (len(allX), image_size, image_size, 1))
|
| 30 |
-
|
| 31 |
-
|
| 32 |
def basic_box_array(image_size):
|
| 33 |
A = numpy.zeros((int(image_size), int(image_size))) # Initializes A matrix with 0 values
|
| 34 |
# Creates the outside edges of the box
|
|
@@ -287,8 +266,8 @@ def interpolate(t1, t2, d1, d2, th1, th2, steps):
|
|
| 287 |
latent_matrix.append(new_column)
|
| 288 |
latent_matrix = numpy.array(latent_matrix).T # Transposes the matrix so that each row can be easily indexed
|
| 289 |
|
| 290 |
-
plot_rows = 2
|
| 291 |
-
plot_columns = num_interp + 2
|
| 292 |
|
| 293 |
predicted_interps = [number_1_expand[0, :, :, 0]]
|
| 294 |
|
|
|
|
| 5 |
import math
|
| 6 |
from tensorflow.python.framework.ops import disable_eager_execution
|
| 7 |
|
| 8 |
+
# Because important
|
| 9 |
disable_eager_execution()
|
| 10 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 11 |
def basic_box_array(image_size):
|
| 12 |
A = numpy.zeros((int(image_size), int(image_size))) # Initializes A matrix with 0 values
|
| 13 |
# Creates the outside edges of the box
|
|
|
|
| 266 |
latent_matrix.append(new_column)
|
| 267 |
latent_matrix = numpy.array(latent_matrix).T # Transposes the matrix so that each row can be easily indexed
|
| 268 |
|
| 269 |
+
# plot_rows = 2
|
| 270 |
+
# plot_columns = num_interp + 2
|
| 271 |
|
| 272 |
predicted_interps = [number_1_expand[0, :, :, 0]]
|
| 273 |
|
data/train_test_split_data.npz
DELETED
|
Binary file (32.1 kB)
|
|
|