Commit 3e485650 authored by zhuwenwen's avatar zhuwenwen
Browse files

增加稠密模型channelwise autotuning 接口

parent 4080ac85
......@@ -613,6 +613,7 @@ class CompressedTensorsLinearMethod(LinearMethodBase):
_weight=weight_data.T.contiguous().reshape(n,-1)
layer.weight.data=_weight
self.tritonsingleton.gen_model_json()
layer.scheme.process_weights_after_loading(layer)
def create_weights(self, layer: torch.nn.Module,
......
......@@ -1900,7 +1900,7 @@ class W8a8GetCacheJSON:
self.quant_method=None
#析构函数,最后会生成model.json的配置文件
def gen_model_json(self,E:int,block_size:Optional[list]=None):
def gen_model_json(self,E:Optional[int]=0,block_size:Optional[list]=None):
json_dir = os.getenv('LMSLIM_TUNING_JSON', "None")
if json_dir is not "None" and os.path.exists(json_dir):
#生成模型配置文件
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment