Shortcuts

Function c10::_fastEqualsForContainer

Function Documentation

bool c10::_fastEqualsForContainer(const IValue &lhs, const IValue &rhs)

We primarily have this for consistency, because Python does the same thing. This actually provokes user-visible changes in behavior due to quirks in torch: [tensor1] == [tensor1] -> True (because container equality will first compare identity) [tensor1] == [tensor1_copy] -> RuntimeError: Boolean value of Tensor with more than one value is ambiguous

Docs

Access comprehensive developer documentation for PyTorch

View Docs

Tutorials

Get in-depth tutorials for beginners and advanced developers

View Tutorials

Resources

Find development resources and get your questions answered

View Resources