MegEngine / MegEngine/InferLLM
isnan报错
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 752
- Forks
- 94
- PR merge metrics
- No merged PRs in 30d
Description
```
In file included from /home/xxx/ClionProjects/InferLLM/src/kern/optimized/x86/quantize.h:3:0,
from /home/xxx/ClionProjects/InferLLM/src/kern/optimized/kernel_opt.cpp:11:
/home/xxx/ClionProjects/InferLLM/src/kern/optimized/x86/quantize.h: In function ‘void inferllm::opt::dequantize_row_q4_0(const void*, float*, int)’:
/home/xxx/ClionProjects/InferLLM/src/kern/optimized/x86/quantize.h:260:46: error: ‘isnan’ was not declared in this scope
assert(!isnan(y[i * QK40 + l + 0]));
^
/home/xxx/ClionProjects/InferLLM/src/kern/optimized/x86/quantize.h:260:46: note: suggested alternative:
In file included from /usr/include/c++/5/random:38:0,
from /home/xxx/ClionProjects/InferLLM/src/utils.h:8,
from /home/xxx/ClionProjects/InferLLM/src/kern/optimized/kernel_opt.cpp:3:
/usr/include/c++/5/cmath:641:5: note: ‘std::isnan’
isnan(_Tp __x)
^
CMakeFiles/InferLLMShared.dir/build.make:257: recipe for target 'CMakeFiles/InferLLMShared.dir/src/kern/optimized/kernel_opt.cpp.o' failed
make[2]: *** [CMakeFiles/InferLLMShared.dir/src/kern/optimized/kernel_opt.cpp.o] Error 1
CMakeFiles/Makefile2:90: recipe for target 'CMakeFiles/InferLLMShared.dir/all' failed
make[1]: *** [CMakeFiles/InferLLMShared.dir/all] Error 2
Makefile:90: recipe for target 'all' failed
make: *** [all] Error 2
```
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with src/kern/optimized/x86/quantize.h around line 260, where the build reports that isnan is not declared. Reproduce the failure with the repository's CMake build and inspect the nearby includes and namespace usage. Done means the InferLLMShared target builds successfully without this error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 50/100