Comments (5)
Please change
Line 201 in 44a9d56
to
set(CMAKE_CXX_STANDARD 17 CACHE STRING "The C++ version to be used.")
and delete your build directory and retry.
Note I was using set(CMAKE_CXX_STANDARD 14)
in the PR.
from k2.
Please try #1249
from k2.
Hi @csukuangfj, thanks for quick reply, but I'm still experiencing issues:
- I see this warning:
/home/videodanchik/k2_builds/k2_gpu/k2/csrc/intersect.cu(889): warning #177-D: variable "num_threads" was declared but never referenced
num_threads = g.size();
^
Remark: The warnings can be suppressed with "-diag-suppress <warning-number>"
Probably the variable can be removed
- The error happens later now:
[ 48%] Building CUDA object k2/csrc/CMakeFiles/context.dir/timer.cu.o
[ 49%] Building CUDA object k2/csrc/CMakeFiles/context.dir/top_sort.cu.o
[ 50%] Building CUDA object k2/csrc/CMakeFiles/context.dir/torch_util.cu.o
In file included from /home/videodanchik/k2_builds/k2_gpu/k2/csrc/pytorch_context.h:26,
from /home/videodanchik/k2_builds/k2_gpu/k2/csrc/torch_util.h:30,
from /home/videodanchik/k2_builds/k2_gpu/k2/csrc/torch_util.cu:23:
/home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/torch/csrc/api/include/torch/all.h:4:2: error: #error C++17 or later compatible compiler is required to use PyTorch.
4 | #error C++17 or later compatible compiler is required to use PyTorch.
| ^~~
In file included from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/c10/util/string_view.h:4,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/c10/util/StringUtil.h:6,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/c10/util/Exception.h:5,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/c10/core/Device.h:5,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/ATen/core/TensorBody.h:11,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/ATen/core/Tensor.h:3,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/ATen/Tensor.h:3,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/torch/csrc/autograd/function_hook.h:3,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/torch/csrc/autograd/cpp_hook.h:2,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/torch/csrc/autograd/variable.h:6,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/torch/csrc/autograd/autograd.h:3,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/torch/csrc/api/include/torch/autograd.h:3,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/torch/csrc/api/include/torch/all.h:7,
from /home/videodanchik/k2_builds/k2_gpu/k2/csrc/pytorch_context.h:26,
from /home/videodanchik/k2_builds/k2_gpu/k2/csrc/torch_util.h:30,
from /home/videodanchik/k2_builds/k2_gpu/k2/csrc/torch_util.cu:23:
/home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/c10/util/C++17.h:27:2: error: #error You need C++17 to compile PyTorch
27 | #error You need C++17 to compile PyTorch
| ^
In file included from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/torch/csrc/api/include/torch/types.h:3,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/torch/csrc/api/include/torch/data/dataloader_options.h:4,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/torch/csrc/api/include/torch/data/dataloader/base.h:3,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/torch/csrc/api/include/torch/data/dataloader/stateful.h:4,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/torch/csrc/api/include/torch/data/dataloader.h:3,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/torch/csrc/api/include/torch/data.h:3,
from /home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/torch/csrc/api/include/torch/all.h:9,
from /home/videodanchik/k2_builds/k2_gpu/k2/csrc/pytorch_context.h:26,
from /home/videodanchik
/k2_builds/k2_gpu/k2/csrc/torch_util.h:30,
from /home/videodanchik/k2_builds/k2_gpu/k2/csrc/torch_util.cu:23:
/home/videodanchik/envs/py311/.venv/lib/python3.11/site-packages/torch/include/ATen/ATen.h:4:2: error: #error C++17 or later compatible compiler is required to use ATen.
4 | #error C++17 or later compatible compiler is required to use ATen.
| ^~~
from k2.
Thanks @csukuangfj, now the build went without any problem, except few warnings like this:
/home/videodanchik/k2_builds/k2_gpu/k2/csrc/intersect.cu(889): warning #177-D: variable "num_threads" was declared but never referenced
num_threads = g.size();
^
Remark: The warnings can be suppressed with "-diag-suppress <warning-number>"
/home/videodanchik/k2_builds/k2_gpu/k2/torch/csrc/wave_reader.cu(61): warning #177-D: variable "p" was declared but never referenced
const char *p = reinterpret_cast<const char *>(&subchunk2_id);
^
Remark: The warnings can be suppressed with "-diag-suppress <warning-number>"
/home/videodanchik/k2_builds/k2_gpu/k2/torch/csrc/beam_search.cu: In function ‘std::vector<std::vector<int>, std::allocator<std::vector<int> > > k2::ModifiedBeamSearch(const torch::jit::Module&, const at::Tensor&, const at::Tensor&, int32_t)’:
/home/videodanchik/k2_builds/k2_gpu/k2/torch/csrc/beam_search.cu:272:20: warning: comparison of integer expressions of different signedness: ‘int32_t’ {aka ‘int’} and ‘std::vector<k2::Hypotheses>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare]
272 | if (cur_batch_size < cur.size()) {
| ~~~~~~~~~~~~~~~^~~~~~~~~~~~
/home/videodanchik/k2_builds/k2_gpu/k2/torch/csrc/beam_search.cu:298:23: warning: comparison of integer expressions of different signedness: ‘int32_t’ {aka ‘int’} and ‘std::vector<k2::Hypothesis>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare]
298 | for (int32_t k = 0; k != prev.size(); ++k) {
| ^~~~~~~~~~~~
/home/videodanchik/k2_builds/k2_gpu/k2/torch/csrc/deserialization.cu: In function ‘void k2::_GLOBAL__N__f882773b_18_deserialization_cu_4aae5ec1::restoreAccurateTypeTags(const c10::IValue&, const TypePtr&)’:
/home/videodanchik/k2_builds/k2_gpu/k2/torch/csrc/deserialization.cu:101:8: warning: enumeration value ‘StorageType’ not handled in switch [-Wswitch]
101 | switch (w.static_type->kind()) {
| ^
/home/videodanchik/k2_builds/k2_gpu/k2/torch/csrc/deserialization.cu:101:8: warning: enumeration value ‘ComplexType’ not handled in switch [-Wswitch]
/home/videodanchik/k2_builds/k2_gpu/k2/torch/csrc/deserialization.cu:101:8: warning: enumeration value ‘AwaitType’ not handled in switch [-Wswitch]
/home/videodanchik/k2_builds/k2_gpu/k2/torch/csrc/deserialization.cu:101:8: warning: enumeration value ‘StreamObjType’ not handled in switch [-Wswitch]
/home/videodanchik/k2_builds/k2_gpu/k2/torch/csrc/deserialization.cu:101:8: warning: enumeration value ‘MemoryFormatType’ not handled in switch [-Wswitch]
/home/videodanchik/k2_builds/k2_gpu/k2/torch/csrc/deserialization.cu:101:8: warning: enumeration value ‘SymIntType’ not handled in switch [-Wswitch]
/home/videodanchik/k2_builds/k2_gpu/k2/torch/csrc/deserialization.cu:101:8: warning: enumeration value ‘SymFloatType’ not handled in switch [-Wswitch]
/home/videodanchik/k2_builds/k2_gpu/k2/torch/csrc/deserialization.cu:101:8: warning: enumeration value ‘SymBoolType’ not handled in switch [-Wswitch]
/home/videodanchik/k2_builds/k2_gpu/k2/torch/csrc/deserialization.cu:101:8: warning: enumeration value ‘UnionType’ not handled in switch [-Wswitch]
/home/videodanchik/k2_builds/k2_gpu/k2/torch/csrc/deserialization.cu:101:8: warning: enumeration value ‘DynamicType’ not handled in switch [-Wswitch]
/home/videodanchik/k2_builds/k2_gpu/k2/torch/bin/attention_rescore.cu: In function ‘int main(int, char**)’:
/home/videodanchik/k2_builds/k2_gpu/k2/torch/bin/attention_rescore.cu:288:17: warning: loop variable ‘tids’ creates a copy from type ‘const std::vector<int>’ [-Wrange-loop-construct]
288 | for (const auto tids : token_ids) {
| ^~~~
/home/videodanchik/k2_builds/k2_gpu/k2/torch/bin/attention_rescore.cu:288:17: note: use reference type to prevent copying
288 | for (const auto tids : token_ids) {
| ^~~~
| &
Thanks for help!
from k2.
Closing via #1249
You can find a list of pre-built wheels at
from k2.
Related Issues (20)
- any possibility / estimation of work necessary to support `mps` device HOT 2
- Use system kaldifeat HOT 1
- in doc of k2 ,there is a mistake in explain for autograd in log semiring HOT 2
- zipformer error HOT 26
- K2 installation on Windowd HOT 15
- Could k2.ctc_graph() be replaced by k2.ctc_topo() + k2.compose() ? HOT 6
- Question about the implementation of MWER HOT 2
- Question about k2.union() function. HOT 4
- Installation on Windows with GPU HOT 2
- FST is going down abruptly. HOT 7
- Can not copy k2.RaggedTensor from CPU to GPU by RaggedTensor.to(device_id) HOT 1
- K2 installation is not working (not up to date for the new cuda and pytorch versions) HOT 4
- A warning is always printed when there is an extreme reduction in the encoder output frame rate. HOT 2
- ModuleNotFoundError: No module named '_k2' HOT 2
- Nbest online decoding bug HOT 15
- argmax_internal::PairInputIterator and argmax_internal::PairOutputIterator don't implement the random access iterator concept HOT 6
- ModuleNotFoundError: No module named '_k2' HOT 5
- error: conflicting declaration ‘typedef struct CUevent_st* HOT 7
- nbest C++ api use too much vram HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from k2.