From 1adc076a02c47088564d8f5d3959e7d80b33000d Mon Sep 17 00:00:00 2001 From: Ajinkya Tejankar Date: Fri, 19 Jul 2024 12:26:32 -0700 Subject: [PATCH] Fix : compile bug causing models to error with 'lora' key not found (#547) --- server/lorax_server/adapters/weights.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/server/lorax_server/adapters/weights.py b/server/lorax_server/adapters/weights.py index 0468baaa8..0857d0677 100644 --- a/server/lorax_server/adapters/weights.py +++ b/server/lorax_server/adapters/weights.py @@ -117,7 +117,9 @@ def from_meta( for k, v in weights.items(): if v.is_empty(): continue - data[k] = v.get_data(meta, prefill, prefill_head_indices if k == LM_HEAD else None) + layer_weights = v.get_data(meta, prefill, prefill_head_indices if k == LM_HEAD else None) + if layer_weights: + data[k] = layer_weights return AdapterBatchData(meta=meta, data=data, prefill=prefill) def ranks(self) -> Set[int]: