code format changes
Signed-off-by: Molly Sophia <mollysophia379@gmail.com>
This commit is contained in:
parent
f2c1a5c918
commit
aaa870e80e
1 changed files with 2 additions and 1 deletions
|
@ -3258,6 +3258,7 @@ class Rwkv6Model(Model):
|
||||||
self.gguf_writer.add_head_count(0)
|
self.gguf_writer.add_head_count(0)
|
||||||
|
|
||||||
lerp_weights: dict[int, dict[str, Tensor]] = {}
|
lerp_weights: dict[int, dict[str, Tensor]] = {}
|
||||||
|
|
||||||
def modify_tensors(self, data_torch: Tensor, name: str, bid: int | None) -> Iterable[tuple[str, Tensor]]:
|
def modify_tensors(self, data_torch: Tensor, name: str, bid: int | None) -> Iterable[tuple[str, Tensor]]:
|
||||||
new_name = self.map_tensor_name(name)
|
new_name = self.map_tensor_name(name)
|
||||||
|
|
||||||
|
@ -3283,7 +3284,7 @@ class Rwkv6Model(Model):
|
||||||
|
|
||||||
# concat time_mix_lerp weights to reduce some cpu overhead
|
# concat time_mix_lerp weights to reduce some cpu overhead
|
||||||
# also reduces the number of tensors in the model
|
# also reduces the number of tensors in the model
|
||||||
if bid is not None and "time_mix_lerp" in new_name and not "time_mix_lerp_x" in new_name:
|
if bid is not None and "time_mix_lerp" in new_name and "time_mix_lerp_x" not in new_name:
|
||||||
try:
|
try:
|
||||||
self.lerp_weights[bid][new_name] = data_torch
|
self.lerp_weights[bid][new_name] = data_torch
|
||||||
except KeyError:
|
except KeyError:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue