Skip to content

Commit e717f5e

Browse files
committed
Fix layer index in debug dumps
1 parent 2a2b9df commit e717f5e

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

include/graph/graph.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ class Graph {
224224
tensors_.push_back(outten_[0]);
225225
#endif
226226
#ifdef ENABLE_STATISTIC_WEIGHTS
227-
weights_.push_back(layers_[i]->get_weights());
227+
weights_.push_back(layers_[current_layer]->get_weights());
228228
#endif
229229

230230
inten_ = outten_;
@@ -270,7 +270,7 @@ class Graph {
270270
auto elapsed =
271271
std::chrono::duration_cast<std::chrono::milliseconds>(end - start);
272272
time_.push_back(static_cast<int>(elapsed.count()));
273-
time_layer_.push_back(layers_[i]->getName());
273+
time_layer_.push_back(layers_[current_layer]->getName());
274274
#endif
275275
}
276276

0 commit comments

Comments
 (0)