|
| 1 | +package org.beehive.gpullama3.tornadovm; |
| 2 | + |
| 3 | +import org.beehive.gpullama3.auxiliary.Tuple2; |
| 4 | +import org.beehive.gpullama3.inference.state.Qwen2State; |
| 5 | +import org.beehive.gpullama3.inference.weights.tornado.Qwen2TornadoWeights; |
| 6 | +import org.beehive.gpullama3.model.Model; |
| 7 | +import org.beehive.gpullama3.model.qwen2.Qwen2Configuration; |
| 8 | +import uk.ac.manchester.tornado.api.GridScheduler; |
| 9 | +import uk.ac.manchester.tornado.api.ImmutableTaskGraph; |
| 10 | +import uk.ac.manchester.tornado.api.TaskGraph; |
| 11 | + |
| 12 | +import java.util.List; |
| 13 | + |
| 14 | +public class Qwen2TornadoVMLayerPlanner extends TornadoVMLayerPlanner<Qwen2State, Qwen2Configuration, Qwen2TornadoWeights> { |
| 15 | + |
| 16 | + /** |
| 17 | + * Constructs a TornadoVMLayerPlanner for the given Llama model. |
| 18 | + * |
| 19 | + * @param state |
| 20 | + * The state object containing model tensors and buffers |
| 21 | + * @param model |
| 22 | + * The Llama model instance containing configuration and weights |
| 23 | + */ |
| 24 | + public Qwen2TornadoVMLayerPlanner(Qwen2State state, Model model) { |
| 25 | + super(state, model); |
| 26 | + } |
| 27 | + |
| 28 | + @Override |
| 29 | + protected TaskGraph configureLayerDataTransfers(TaskGraph unifiedLayer, int layerIndex) { |
| 30 | + throw new UnsupportedOperationException("configureLayerDataTransfers Not supported yet."); |
| 31 | + } |
| 32 | + |
| 33 | + @Override |
| 34 | + public Tuple2<List<ImmutableTaskGraph>, GridScheduler> setupTornadoForwardPlanLayered() { |
| 35 | + throw new UnsupportedOperationException("setupTornadoForwardPlanLayered Not supported yet."); |
| 36 | + } |
| 37 | + |
| 38 | + @Override |
| 39 | + public Tuple2<List<ImmutableTaskGraph>, GridScheduler> setupTornadoForwardPlanLayeredNonNvidia() { |
| 40 | + return setupTornadoForwardPlanLayered(); |
| 41 | + } |
| 42 | + |
| 43 | + private GridScheduler setupQwen2GridSchedulersLayeredNonNvidia() { |
| 44 | + throw new UnsupportedOperationException("setupQwen2GridSchedulersLayeredNonNvidia Not supported yet."); |
| 45 | + } |
| 46 | +} |
0 commit comments