pytorch-wordemb/src/loadwordemb.cpp:101:41: error: non-constant-expression cannot be narrowed from type 'size_t' (aka 'unsigned long') to 'long long' in initializer list [-Wc++11-narrowing]
dest.resize_(torch::IntArrayRef{n_word, dim});
-Wc++11-narrowing
prevents compilation due to incompatible types Typedef Documentation using c10::IntArrayRef = ArrayRef<int64_t>
and
dest.resize_(torch::IntArrayRef{n_word, dim});
correct to:
dest.resize_(torch::IntArrayRef{(int64_t)n_word, (int64_t)dim});
or propose better / correct handling of types...
pytorch-wordemb/src/loadwordemb.cpp:101:41: error: non-constant-expression cannot be narrowed from type 'size_t' (aka 'unsigned long') to 'long long' in initializer list [-Wc++11-narrowing]
dest.resize_(torch::IntArrayRef{n_word, dim});
-Wc++11-narrowing
prevents compilation due to incompatible types Typedef Documentation using c10::IntArrayRef = ArrayRef<int64_t>
and
dest.resize_(torch::IntArrayRef{n_word, dim});
correct to:
dest.resize_(torch::IntArrayRef{(int64_t)n_word, (int64_t)dim});
or propose better / correct handling of types...