Class AbstractRef
Defined in File abstract_value.h
Inheritance Relationships
Base Type
public mindspore::abstract::AbstractTensor
(Class AbstractTensor)
Class Documentation
-
class AbstractRef : public mindspore::abstract::AbstractTensor
Class AbstractRef describes a RefTensor’s abstract value.
Public Functions
-
AbstractRef(const AbstractBasePtr &ref_key, const AbstractTensorPtr &ref_value)
Constructor of AbstractRef.
- Parameters
ref_key – [in] The ref key of tensor.
ref_value – [in] The tensor.
-
~AbstractRef() override = default
Destructor of AbstractEllipsis.
-
inline virtual AbstractBasePtr Clone() const override
Clone an abstract from the abstract.
- Returns
A pointer to the cloned abstract.
-
inline AbstractBasePtr CloneAsTensor() const
Use parent’s AbstractTensor::Clone() to clone an abstract.
- Returns
A pointer to the cloned abstract.
-
virtual std::string ToString() const override
Get the string representation of this object.
- Returns
The string representation.
-
inline AbstractTensorPtr ref()
Get the abstract tensor, which is referenced.
- Returns
A pointer to the abstract tensor.
-
inline AbstractBasePtr ref_key() const
Get the ref key.
- Returns
A pointer to the abstract key.
-
inline RefKeyPtr ref_key_value() const
Get the ref key value.
- Returns
A point to the RefKey.
-
inline virtual AbstractBasePtr Broaden() const override
Broaden the abstract. It will upgrade the abstract to a higher level.
- Returns
A pointer to the broadened abstract.
-
virtual AbstractBasePtr Join(const AbstractBasePtr &other) override
Combine two abstracts. If two abstracts are different, it will broaden the abstract value.
- Parameters
other – [in] The other abstract to be joined.
- Returns
A pointer to the combined abstract.
-
inline virtual std::size_t hash() const override
Get the hash value of this object.
- Returns
The hash value.
-
virtual AbstractBasePtr PartialBroaden() const override
Broaden abstract with constraints.
- Returns
A pointer to the broadened abstract.
-
AbstractRef(const AbstractBasePtr &ref_key, const AbstractTensorPtr &ref_value)