frontend to audio dir

pull/1640/head
Hui Zhang 3 years ago
parent 8d66a254da
commit 42c7537ce6

@ -17,7 +17,7 @@
#include "base/flags.h"
#include "base/log.h"
#include "decoder/ctc_beam_search_decoder.h"
#include "frontend/data_cache.h"
#include "frontend/audio/data_cache.h"
#include "kaldi/util/table-types.h"
#include "nnet/decodable.h"
#include "nnet/paddle_nnet.h"

@ -17,7 +17,7 @@
#include "base/flags.h"
#include "base/log.h"
#include "decoder/ctc_beam_search_decoder.h"
#include "frontend/data_cache.h"
#include "frontend/audio/data_cache.h"
#include "kaldi/util/table-types.h"
#include "nnet/decodable.h"
#include "nnet/paddle_nnet.h"

@ -14,19 +14,18 @@
// todo refactor, repalce with gtest
#include "frontend/linear_spectrogram.h"
#include "base/flags.h"
#include "base/log.h"
#include "frontend/audio_cache.h"
#include "frontend/data_cache.h"
#include "frontend/feature_cache.h"
#include "frontend/frontend_itf.h"
#include "frontend/normalizer.h"
#include "kaldi/feat/wave-reader.h"
#include "kaldi/util/kaldi-io.h"
#include "kaldi/util/table-types.h"
#include <glog/logging.h>
#include "frontend/audio/linear_spectrogram.h"
#include "frontend/audio/audio_cache.h"
#include "frontend/audio/data_cache.h"
#include "frontend/audio/feature_cache.h"
#include "frontend/audio/frontend_itf.h"
#include "frontend/audio/normalizer.h"
DEFINE_string(wav_rspecifier, "", "test wav scp path");
DEFINE_string(feature_wspecifier, "", "output feats wspecifier");

@ -1,11 +1,2 @@
project(frontend)
add_library(frontend STATIC
cmvn.cc
db_norm.cc
linear_spectrogram.cc
audio_cache.cc
feature_cache.cc
)
target_link_libraries(frontend PUBLIC kaldi-matrix)
add_subdirectory(audio)

@ -0,0 +1,11 @@
project(frontend)
add_library(frontend STATIC
cmvn.cc
db_norm.cc
linear_spectrogram.cc
audio_cache.cc
feature_cache.cc
)
target_link_libraries(frontend PUBLIC kaldi-matrix)

@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "frontend/audio_cache.h"
#include "frontend/audio/audio_cache.h"
#include "kaldi/base/timer.h"
namespace ppspeech {

@ -16,7 +16,7 @@
#pragma once
#include "base/common.h"
#include "frontend/frontend_itf.h"
#include "frontend/audio/frontend_itf.h"
namespace ppspeech {

@ -1,5 +1,5 @@
#include "frontend/normalizer.h"
#include "frontend/audio/cmvn.h"
#include "kaldi/feat/cmvn.h"
#include "kaldi/util/kaldi-io.h"
@ -13,7 +13,6 @@ using kaldi::SubVector;
using std::unique_ptr;
CMVN::CMVN(std::string cmvn_file,
unique_ptr<FrontendInterface> base_extractor)
: var_norm_(true) {

@ -1,7 +1,7 @@
#pragma once
#include "base/common.h"
#include "frontend/frontend_itf.h"
#include "frontend/audio/frontend_itf.h"
#include "kaldi/matrix/kaldi-matrix.h"
#include "kaldi/util/options-itf.h"

@ -17,7 +17,7 @@
#include "base/common.h"
#include "frontend/frontend_itf.h"
#include "frontend/audio/frontend_itf.h"
namespace ppspeech {

@ -13,7 +13,7 @@
// limitations under the License.
#include "frontend/normalizer.h"
#include "frontend/audio/db_norm.h"
#include "kaldi/feat/cmvn.h"
#include "kaldi/util/kaldi-io.h"

@ -16,7 +16,7 @@
#pragma once
#include "base/common.h"
#include "frontend/frontend_itf.h"
#include "frontend/audio/frontend_itf.h"
#include "kaldi/matrix/kaldi-matrix.h"
#include "kaldi/util/options-itf.h"

@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "frontend/feature_cache.h"
#include "frontend/audio/feature_cache.h"
namespace ppspeech {

@ -15,7 +15,7 @@
#pragma once
#include "base/common.h"
#include "frontend/frontend_itf.h"
#include "frontend/audio/frontend_itf.h"
namespace ppspeech {

@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "frontend/linear_spectrogram.h"
#include "frontend/audio/linear_spectrogram.h"
#include "kaldi/base/kaldi-math.h"
#include "kaldi/matrix/matrix-functions.h"

@ -16,7 +16,7 @@
#pragma once
#include "base/common.h"
#include "frontend/frontend_itf.h"
#include "frontend/audio/frontend_itf.h"
#include "kaldi/feat/feature-window.h"
namespace ppspeech {

@ -0,0 +1,4 @@
#pragma once
#include "frontend/audio/cmvn.h"
#include "frontend/audio/db_norm.h"

@ -1,4 +0,0 @@
#pragma once
#include "frontend/cmvn.h"
#include "frontend/db_norm.h"

@ -1,15 +0,0 @@
// Copyright (c) 2022 PaddlePaddle Authors. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
// extract the window of kaldi feat.

@ -13,7 +13,7 @@
// limitations under the License.
#include "base/common.h"
#include "frontend/frontend_itf.h"
#include "frontend/audio/frontend_itf.h"
#include "kaldi/matrix/kaldi-matrix.h"
#include "nnet/decodable-itf.h"
#include "nnet/nnet_interface.h"

Loading…
Cancel
Save