54 const auto &tgraph = *tdata.tgraph;
56 auto tr = std::make_shared<TensorRegistry>();
57 auto tb = std::make_shared<TensorBuilder>(tr, optimizer.get());
58 auto tdata_ptr = std::make_unique<backend::train::TrainableContextData>(std::move(tdata));
59 auto context = std::make_unique<train::BackendContext>(
this, std::move(tdata_ptr), tr, tb,
60 std::move(optimizer));
62 context->kernel_gen = std::make_shared<train::KernelGenerator>(
63 tgraph, tr, context->external_context(), context->optimizer());