mirror of
https://github.com/2noise/ChatTTS.git
synced 2026-08-30 17:05:27 +08:00
chore(format): run black on dev (#626)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
b165532bdc
commit
e508fee76c
@@ -516,6 +516,7 @@ class Chat:
|
||||
|
||||
if gpt.is_vllm:
|
||||
from .model.velocity.sampling_params import SamplingParams
|
||||
|
||||
sample_params = SamplingParams(
|
||||
temperature=temperature,
|
||||
max_new_token=params.max_new_token,
|
||||
@@ -613,6 +614,7 @@ class Chat:
|
||||
|
||||
if gpt.is_vllm:
|
||||
from .model.velocity.sampling_params import SamplingParams
|
||||
|
||||
sample_params = SamplingParams(
|
||||
temperature=params.temperature,
|
||||
max_new_token=params.max_new_token,
|
||||
|
||||
@@ -94,6 +94,7 @@ class GPT(nn.Module):
|
||||
if self.is_vllm and platform.system().lower() == "linux":
|
||||
from .velocity.llm import LLM
|
||||
from .velocity.post_model import PostModel
|
||||
|
||||
vllm_folder = Path(os.getcwd()) / "asset" / "vllm"
|
||||
if not os.path.exists(vllm_folder):
|
||||
self.logger.info("initializing vLLM model to %s", str(vllm_folder))
|
||||
@@ -405,7 +406,9 @@ class GPT(nn.Module):
|
||||
attention_mask: Optional[torch.Tensor] = None,
|
||||
max_new_token=2048,
|
||||
min_new_token=0,
|
||||
logits_processors: Tuple[Callable[[torch.LongTensor, torch.FloatTensor], torch.FloatTensor]] = (),
|
||||
logits_processors: Tuple[
|
||||
Callable[[torch.LongTensor, torch.FloatTensor], torch.FloatTensor]
|
||||
] = (),
|
||||
infer_text=False,
|
||||
return_attn=False,
|
||||
return_hidden=False,
|
||||
|
||||
Reference in New Issue
Block a user