Skip to content

Commit

Permalink
Fix BitNet weights loading
Browse files Browse the repository at this point in the history
  • Loading branch information
kaleid-liner committed Jun 5, 2024
1 parent 3ccb45d commit cda0780
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ggml-tmac.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -190,9 +190,9 @@ void ggml_tmac_transform_tensor(struct ggml_tensor * tensor) {
qweights = (uint8_t *) aligned_malloc(k * m / 8);
} else {
qweights = (uint8_t *)tensor->data;
float * scale = (float * )((qweights) + (k * m) / 8);
float * i2_scales = (float * )(qweights + k * m / 8);
for (int i = 0; i < scales_size; i++) {
scales[i] = *scale;
scales[i] = (tmac_float_type) i2_scales[i];
}
}

Expand Down

0 comments on commit cda0780

Please sign in to comment.