Unverified Commit 494469d4 authored by Atream's avatar Atream Committed by GitHub
Browse files

Merge pull request #722 from ZhangShuaiyi/remove_unused

Delete duplicate code
parents 1264f940 a34a25d5
...@@ -170,7 +170,6 @@ def prefill_and_generate(model, tokenizer, inputs, max_new_tokens=10000, use_cud ...@@ -170,7 +170,6 @@ def prefill_and_generate(model, tokenizer, inputs, max_new_tokens=10000, use_cud
past_key_values.cur_idx=cache_position past_key_values.cur_idx=cache_position
start_time = time.time() start_time = time.time()
inputs_embeds = model.model.embed_tokens(inputs.to("cpu")).to(torch_device)
if mode == "long_context": if mode == "long_context":
inputs_embeds = model.model.embed_tokens(inputs.to("cpu")) inputs_embeds = model.model.embed_tokens(inputs.to("cpu"))
else: else:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment