@@ -46,7 +46,7 @@ def test_sync_fit_deploy(pytorch_training_job, sagemaker_session):
46
46
predictor .predict (data )
47
47
48
48
batch_size = 100
49
- data = numpy .rand (shape = ( 100 , 1 , 28 , 28 ) )
49
+ data = numpy .random . rand (batch_size , 1 , 28 , 28 )
50
50
output = predictor .predict (data )
51
51
52
52
assert numpy .asarray (output ).shape == (batch_size , 10 )
@@ -62,7 +62,7 @@ def test_deploy_model(pytorch_training_job, sagemaker_session):
62
62
predictor = model .deploy (1 , 'ml.m4.xlarge' , endpoint_name = endpoint_name )
63
63
64
64
batch_size = 100
65
- data = numpy .rand (shape = ( 100 , 1 , 28 , 28 ) )
65
+ data = numpy .random . rand (batch_size , 1 , 28 , 28 )
66
66
output = predictor .predict (data )
67
67
68
68
assert numpy .asarray (output ).shape == (batch_size , 10 )
@@ -91,7 +91,7 @@ def test_async_fit_deploy(sagemaker_session, pytorch_full_version):
91
91
predictor = estimator .deploy (1 , instance_type , endpoint_name = endpoint_name )
92
92
93
93
batch_size = 100
94
- data = numpy .rand (shape = ( 100 , 1 , 28 , 28 ) )
94
+ data = numpy .random . rand (batch_size , 1 , 28 , 28 )
95
95
output = predictor .predict (data )
96
96
97
97
assert numpy .asarray (output ).shape == (batch_size , 10 )
0 commit comments