134{
135 planForwardTensors();
136 planBackwardTensors();
137
138 _tensor_builder->allocate();
139 _tensor_builder->allocateBackward();
140
141 auto fn_map = generateFunctionMap();
142
143
147 return;
148
150 assert(tensor != nullptr);
151
152 VERBOSE(FillOperandData) <<
"Fill data for " << ind << std::endl;
153
154 auto data = operand.shareData();
157
158 if (trainable_tensor == nullptr)
159 throw std::runtime_error{"This tensor is not trainable tensor"};
160
162 });
163
164
165 const_cast<ir::train::TrainableGraph &
>(*
_tdata->tgraph)
166 .operands()
168
169
170
171
172
173
174
175
176
177
178 planLayerScopeTensors(fn_map);
179 _tensor_builder->allocateLayerScope();
180
181 return fn_map;
182}
void fillBuffer(const std::shared_ptr< ir::Data > &data)
const TrainableContextData * data() const
const ir::train::TrainableGraph * trainable_graph() const
const util::Set< ir::OperandIndex > & external_operands() const
std::unique_ptr< TrainableContextData > _tdata
const Operands & operands() const override
void iterate(const std::function< void(const Index &, const Object &)> &fn) const
Iterate over the container with given function.
#define VERBOSE(name, lv)
basic::train::TrainableTensor TrainableTensor
::onert::util::Index< uint32_t, OperandIndexTag > OperandIndex