MCPcopy Create free account
hub / github.com/Tiiny-AI/PowerInfer / load

Function load

convert-dense.py:564–567  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

562 concatenated_shape[axis] = sum(tensor.shape[axis] for tensor in lazy_tensors)
563
564 def load() -> UnquantizedTensor:
565 ndarrays = [load_unquantized(tensor) for tensor in lazy_tensors]
566 concatenated: NDArray = np.concatenate(ndarrays, axis=axis)
567 return UnquantizedTensor(concatenated)
568 description = 'concatenated[[' + '] | ['.join(lt.description for lt in lazy_tensors) + ']]'
569 return LazyTensor(load, concatenated_shape, lazy_tensors[0].data_type, description)
570 return {name: convert(name) for name in names}

Callers

nothing calls this directly

Calls 7

reshapeMethod · 0.80
load_unquantizedFunction · 0.70
UnquantizedTensorClass · 0.70
permuteMethod · 0.45
loadMethod · 0.45
permute_partMethod · 0.45
partMethod · 0.45

Tested by

no test coverage detected