Skip to content

Commit 3f24fb3

Browse files
Use Configuration.quantization() method in Activation
1 parent e63d919 commit 3f24fb3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/main/java/org/beehive/gpullama3/tornadovm/layers/Activation.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ public Activation(String taskGraphHandle, State state, Weights weights, Configur
2424
KernelContext kernelContext = new KernelContext();
2525

2626
// @formatter:off
27-
switch (config.modelType()) {
27+
switch (config.quantization()) {
2828
case "FP16" -> {
2929
this.activationUpdate = new TaskGraph(taskGraphHandle)
3030
.transferToDevice(DataTransferMode.EVERY_EXECUTION, state.embeddingX)
@@ -37,7 +37,7 @@ public Activation(String taskGraphHandle, State state, Weights weights, Configur
3737
.task("updateX", TransformerComputeKernels::convertQ8_0toFP32, kernelContext, (ByteArray) state.embeddingX, state.wrapX)
3838
.persistOnDevice(state.wrapX);
3939
}
40-
default -> throw new UnsupportedOperationException("Quantization format " + config.modelType());
40+
default -> throw new UnsupportedOperationException("Unsupported quantization format: " + config.quantization());
4141
}
4242
// @formatter:on
4343
}

0 commit comments

Comments
 (0)