Skip to content

Commit

Permalink
fix: gpu change to cpu overhead (#656)
Browse files Browse the repository at this point in the history
* fix: gpu change to cpu overhead

* Update .gitignore

---------

Co-authored-by: 源文雨 <[email protected]>
  • Loading branch information
wenyangchou and fumiama authored Aug 1, 2024
1 parent 6e2b0ae commit e483d55
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
3 changes: 1 addition & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -160,13 +160,12 @@ cython_debug/
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
# and can be added to the global gitignore or merged into this file. For a more nuclear
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
#.idea/
.idea/

# MacOS System
.DS_Store

# assets and configs of ChatTTS

/asset
/config

Expand Down
6 changes: 3 additions & 3 deletions ChatTTS/model/velocity/model_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -567,9 +567,9 @@ def execute_model(
# )
results = []
for i in range(idx_next.shape[0]):
idx_next_i = idx_next[i, 0, :].cpu().tolist()
logprob_i = logprob[i].cpu().tolist()
tmp_hidden_states = hidden_states[i].cpu()
idx_next_i = idx_next[i, 0, :].tolist()
logprob_i = logprob[i].tolist()
tmp_hidden_states = hidden_states[i]
if input_tokens[i].shape[-2] != 1:
tmp_hidden_states = tmp_hidden_states[-1:, :]
result = SequenceGroupOutput(
Expand Down

0 comments on commit e483d55

Please sign in to comment.