Commit 0de304ca by ziheng Committed by Tianqi Chen

Rename TShape::index_t to dim_t and change to int64_t (#114)

* Change TShape::index_t to int64_t

* Add comment

* Make Tuple::Save&Load dtype generic

* trigger update

* Fix lint

* Fix comment

* Change index_t to dim_t

* Remove legacy index_t
parent 56ea6d6b
......@@ -156,7 +156,7 @@ Graph Gradient(Graph src) {
CHECK_EQ((*rit)->inputs.size(), input_grads.size())
<< "Gradient function not returning enough gradient";
} else if (CheckGradAllZero(out_agg_grads, zero_ops)) {
for (index_t i = 0; i < fwd_node->num_inputs(); ++i) {
for (size_t i = 0; i < fwd_node->num_inputs(); ++i) {
std::ostringstream os;
if (1 == fwd_node->num_inputs()) {
os << fwd_node->attrs.name << "_backward";
......
......@@ -17,7 +17,7 @@ TEST(Tuple, Basic) {
std::istringstream is(os.str());
is >> y;
CHECK_EQ(x, y);
Tuple<nnvm::index_t> ss{1, 2, 3};
Tuple<nnvm::dim_t> ss{1, 2, 3};
TShape s = ss;
s = std::move(ss);
CHECK((s == TShape{1, 2, 3}));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment