Skip to content

tenzr::DynamicUpdateSliceNode

More...

#include <node.h>

Inherits from tenzr::Node, std::enable_shared_from_this< Node >

Public Functions

Name
DynamicUpdateSliceNode(std::shared_ptr< Node > operand, std::shared_ptr< Node > update, std::vector< std::shared_ptr< Node > > start_indices)
virtual std::string OpName() const override
StableHLO-style name of this node's operation.
const std::shared_ptr< Node > & Operand() const
const std::shared_ptr< Node > & Update() const

Additional inherited members

Public Functions inherited from tenzr::Node

Name
Node(NodeKind kind, Shape shape, DType dtype, ShardingSpec sharding =ShardingSpec::Replicated())
virtual ~Node() =default
NodeKind Kind() const
The node's operation kind.
const Shape & shape() const
The node's output shape.
DType Dtype() const
The node's output dtype.
const ShardingSpec & Sharding() const
The node's sharding spec.
void SetSharding(ShardingSpec spec)
Replace the sharding spec.
const StridedLayout & Layout() const
The node's strided layout.
void SetLayout(StridedLayout layout)
Replace the layout.
const std::vector< std::shared_ptr< Node > > & Inputs() const
The node's input operands.
uint64_t Id() const
The node's unique id.

Protected Functions inherited from tenzr::Node

Name
uint64_t NextId()

Protected Attributes inherited from tenzr::Node

Name
NodeKind kind_
Shape shape_
DType dtype_
ShardingSpec sharding_
StridedLayout layout_
std::vector< std::shared_ptr< Node > > inputs_
uint64_t id_

Detailed Description

class tenzr::DynamicUpdateSliceNode;

Write an update into a slice of an operand at runtime-computed start indices.

Public Functions Documentation

function DynamicUpdateSliceNode

DynamicUpdateSliceNode(
    std::shared_ptr< Node > operand,
    std::shared_ptr< Node > update,
    std::vector< std::shared_ptr< Node > > start_indices
)

Parameters:

  • operand Target node.
  • update Values written into the slice.
  • start_indices Per-dimension start indices.

Create a dynamic-update-slice node with runtime start indices.

function OpName

inline virtual std::string OpName() const override

StableHLO-style name of this node's operation.

Reimplements: tenzr::Node::OpName

function Operand

inline const std::shared_ptr< Node > & Operand() const

function Update

inline const std::shared_ptr< Node > & Update() const