File tree Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -68,8 +68,15 @@ def __post_init__(self) -> None:
68
68
self .long_prefill_token_threshold = \
69
69
max (1 , int (self .max_model_len * 0.04 ))
70
70
71
- assert (self .max_long_partial_prefills > 0 )
72
- assert (self .long_prefill_token_threshold > 0 )
71
+ if self .max_long_partial_prefills <= 0 :
72
+ raise ValueError (
73
+ f"max_long_partial_prefills must be positive, but got "
74
+ f"{ self .max_long_partial_prefills } " )
75
+ if self .long_prefill_token_threshold <= 0 :
76
+ raise ValueError (
77
+ f"long_prefill_token_threshold must be positive, but got "
78
+ f"{ self .long_prefill_token_threshold } " )
79
+
73
80
if self .policy != "fcfs" :
74
81
raise NotImplementedError (
75
82
f"currently AscendScheduler only supports fcfs policy, got { self .policy } "
You can’t perform that action at this time.
0 commit comments