TensorPlay
Copy
View Markdown

Source code for tensorplay.autograd.variable

"""Tensor variable compatibility names for the automatic differentiation API."""

import tensorplay

__all__ = ["VariableMeta", "Variable"]



[docs]
class VariableMeta(type):
    def __instancecheck__(cls, other):
        return isinstance(other, tensorplay.Tensor)




[docs]
class Variable(metaclass=VariableMeta):
    _execution_engine = tensorplay._C._autograd
Ask DeepWiki