torch.Tensor.expand_as¶
- Tensor.expand_as(other) 张量¶
将此张量扩展为与
other相同的大小。self.expand_as(other)等同于self.expand(other.size())。请参阅
expand()以获取更多关于expand的信息。- Parameters
其他 (
torch.Tensor) – 结果张量与other具有相同的大小。
将此张量扩展为与 other 相同的大小。
self.expand_as(other) 等同于 self.expand(other.size())。
请参阅expand()以获取更多关于expand的信息。
其他 (torch.Tensor) – 结果张量与 other 具有相同的大小。