Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
vbvg2008 committed Jun 18, 2019
2 parents c717063 + 0d2ceb1 commit 1fead2b
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions benchmark/pipeline_performance.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
from fastestimator.pipeline.static.preprocess import Minmax
from fastestimator.pipeline.pipeline import Pipeline
import tensorflow as tf
import numpy as np

(x_train, y_train), (x_eval, y_eval) = tf.keras.datasets.mnist.load_data()
x_train = np.expand_dims(x_train, -1)

pipeline = Pipeline(batch_size=32,
feature_name=["x", "y"],
train_data={"x": x_train, "y": y_train},
validation_data= {"x": x_eval, "y": y_eval},
transform_train= [[Minmax()], []])

pipeline.benchmark(num_steps=3000, mode="train")

0 comments on commit 1fead2b

Please sign in to comment.