Skip to content

Commit

Permalink
faster api tests
Browse files Browse the repository at this point in the history
  • Loading branch information
IlyasMoutawwakil committed Apr 14, 2024
1 parent 4425513 commit 2ce05d9
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions tests/test_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,10 @@ def test_api_launch(device, benchmark, library, task, model):
memory=True,
latency=True,
duration=1,
iterations=1,
warmup_runs=1,
input_shapes={"batch_size": 1, "sequence_length": 16},
generate_kwargs={"max_new_tokens": 5, "min_new_tokens": 5},
input_shapes={"batch_size": 1, "sequence_length": 2},
generate_kwargs={"max_new_tokens": 2, "min_new_tokens": 2},
call_kwargs={"num_inference_steps": 2},
energy=torch.version.hip is None,
)
Expand Down Expand Up @@ -98,7 +99,7 @@ def test_api_push_to_hub_mixin():

launcher_config = ProcessConfig(device_isolation=False)
backend_config = PyTorchConfig(model="google-bert/bert-base-uncased", device="cpu")
benchmark_config = InferenceConfig(memory=True, latency=True, duration=1, warmup_runs=1)
benchmark_config = InferenceConfig(memory=True, latency=True, duration=1, iterations=1, warmup_runs=1)

experiment_config = ExperimentConfig(
experiment_name=experiment_name,
Expand Down

0 comments on commit 2ce05d9

Please sign in to comment.