Class AbstractSlice

Inheritance Relationships

Base Type

Class Documentation

class AbstractSlice : public mindspore::abstract::AbstractBase

Class AbstractSlice describes a slice node’s abstract value.

Public Functions

inline AbstractSlice(const AbstractBasePtr &start, const AbstractBasePtr &stop, const AbstractBasePtr &step)

Constructor of AbstractSlice.

Parameters
  • start[in] The start index of slice.

  • stop[in] The stop index of slice.

  • step[in] The step size of slice.

~AbstractSlice() override = default

Destructor of AbstractSlice.

virtual AbstractBasePtr Clone() const override

Clone an abstract from the abstract.

Returns

A pointer to the cloned abstract.

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 std::string ToString() const override

Get the string representation of this object.

Returns

The string representation.

virtual std::size_t hash() const override

Get the hash value of this object.

Returns

The hash value.

inline AbstractBasePtr start() const

Get the start index of slice.

Returns

A point to the abstract of start index.

inline AbstractBasePtr stop() const

Get the stop index of slice.

Returns

A point to the abstract of stop index.

inline AbstractBasePtr step() const

Get the step size of slice.

Returns

A point to the abstract of step number.