Fix generated-shared-prefix bench_serving (#18769)
This commit is contained in:
@@ -1525,12 +1525,12 @@ def sample_custom_requests(
|
|||||||
return filtered_dataset
|
return filtered_dataset
|
||||||
|
|
||||||
|
|
||||||
def compute_random_lens(full_len: int, range_ratio: float, num: int) -> List[int]:
|
def compute_random_lens(full_len: int, range_ratio: float, num: int) -> np.ndarray:
|
||||||
return np.random.randint(
|
return np.random.randint(
|
||||||
max(int(full_len * range_ratio), 1),
|
max(int(full_len * range_ratio), 1),
|
||||||
full_len + 1,
|
full_len + 1,
|
||||||
size=num,
|
size=num,
|
||||||
).tolist()
|
)
|
||||||
|
|
||||||
|
|
||||||
def sample_random_requests(
|
def sample_random_requests(
|
||||||
|
|||||||
Reference in New Issue
Block a user