chenkui164 / FastASR

这是一个用C++实现ASR推理的项目,它依赖很少,安装也很简单,推理速度很快,在树莓派4B等ARM平台也可以流畅的运行。 支持的模型是由Google的Transformer模型中优化而来,数据集是开源wenetspeech(10000+小时)或阿里私有数据集(60000+小时), 所以识别效果也很好,可以媲美许多商用的ASR软件。
Apache License 2.0
481 stars 74 forks source link

fatal error: 'fftw3.h' file not found #7

Closed jkluo closed 2 years ago

jkluo commented 2 years ago

brew install fftw 安装好后,make的时候还是提示 fatal error: 'fftw3.h' file not found。

ll /usr/local/include total 296 drwxr-xr-x 7 root wheel 224 8 8 14:06 ./ drwxr-xr-x 6 root wheel 192 8 8 14:06 ../ -rw-r--r-- 1 root wheel 2447 8 8 14:06 fftw3.f -rw-r--r-- 1 root wheel 55032 8 8 14:06 fftw3.f03 -rw-r--r-- 1 root wheel 31986 8 8 14:06 fftw3.h -rw-r--r-- 1 root wheel 27203 8 8 14:06 fftw3l.f03 -rw-r--r-- 1 root wheel 25902 8 8 14:06 fftw3q.f03

chenkui164 commented 2 years ago

@jkluo 修改一下CMakeLists.txt

找到fftw的include的目录和lib目录,修改成本机所在位置

target_include_directories(fastasr PUBLIC "/usr/local/opt/fftw/include") target_link_directories(fastasr PUBLIC "/usr/local/opt/fftw/lib")

找到openblas的include的目录和lib目录,修改成本机所在位置

target_include_directories(fastasr PUBLIC "/usr/local/opt/openblas/include") target_link_directories(fastasr PUBLIC "/usr/local/opt/openblas/lib")

jkluo commented 2 years ago

在[CMakeLists.txt] 上加了路径后解决了。

cmake_minimum_required(VERSION 3.10)

set (CMAKE_CXX_STANDARD 11)

project(FastASR)

add_subdirectory(lib) add_subdirectory(examples)

target_include_directories(fastasr PUBLIC "/opt/homebrew/opt/fftw/include") target_link_directories(fastasr PUBLIC "/opt/homebrew/opt/fftw/lib")

target_include_directories(fastasr PUBLIC "/opt/homebrew/opt/openblas/include") target_link_directories(fastasr PUBLIC "/opt/homebrew/opt/openblas/lib")