torch_npu.npu_sign_bits_unpack(x, dtype, size) -> Tensor
将uint8类型1位Adam拆包为float。
Size可被uint8s拆包的输出整除。输出大小为(size of x) * 8。
>>>a = torch.tensor([159, 15], dtype=torch.uint8).npu()
>>>b = torch_npu.npu_sign_bits_unpack(a, 0, 2)
>>>b
>>>tensor([[1., 1., 1., 1., 1., -1., -1., 1.],
>>>[1., 1., 1., 1., -1., -1., -1., -1.]], device='npu:0')
(binary form of 159 is ob00001111)