parent
e1e1dd6356
commit
f94cb4832b
@ -0,0 +1,3 @@
|
||||
build
|
||||
third_party/archives/
|
||||
third_party/install/
|
@ -0,0 +1,8 @@
|
||||
#include "pybind/sox/io.h"
|
||||
|
||||
PYBIND11_MODULE(_paddleaudio, m) {
|
||||
m.def("get_info_file", &paddleaudio::sox_io::get_info_file,
|
||||
"Get metadata of audio file.");
|
||||
m.def("get_info_fileobj", &paddleaudio::sox_io::get_info_fileobj,
|
||||
"Get metadata of audio in file object.");
|
||||
}
|
@ -1,19 +1,5 @@
|
||||
// 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.
|
||||
|
||||
#include <paddleaudio/csrc/pybind/sox/io.h>
|
||||
#include <paddleaudio/csrc/pybind/sox/utils.h>
|
||||
#include "pybind/sox/io.h"
|
||||
#include "pybind/sox/utils.h"
|
||||
|
||||
using namespace paddleaudio::sox_utils;
|
||||
|
@ -0,0 +1,18 @@
|
||||
#ifndef PADDLEAUDIO_PYBIND_SOX_IO_H
|
||||
#define PADDLEAUDIO_PYBIND_SOX_IO_H
|
||||
|
||||
#include "pybind/sox/utils.h"
|
||||
|
||||
namespace paddleaudio {
|
||||
namespace sox_io {
|
||||
|
||||
auto get_info_file(const std::string &path, const std::string &format)
|
||||
-> std::tuple<int64_t, int64_t, int64_t, int64_t, std::string>;
|
||||
|
||||
auto get_info_fileobj(py::object fileobj, const std::string &format)
|
||||
-> std::tuple<int64_t, int64_t, int64_t, int64_t, std::string>;
|
||||
|
||||
} // namespace paddleaudio
|
||||
} // namespace sox_io
|
||||
|
||||
#endif
|
@ -1,18 +1,4 @@
|
||||
// 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.
|
||||
|
||||
#include <paddleaudio/csrc/pybind/sox/utils.h>
|
||||
#include "pybind/sox/utils.h"
|
||||
|
||||
#include <sstream>
|
||||
|
@ -1,17 +1,3 @@
|
||||
// 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.
|
||||
|
||||
#ifndef PADDLEAUDIO_PYBIND_SOX_UTILS_H
|
||||
#define PADDLEAUDIO_PYBIND_SOX_UTILS_H
|
||||
|
@ -1,22 +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.
|
||||
|
||||
#include <paddleaudio/csrc/pybind/sox/io.h>
|
||||
|
||||
PYBIND11_MODULE(_paddleaudio, m) {
|
||||
m.def("get_info_file", &paddleaudio::sox_io::get_info_file,
|
||||
"Get metadata of audio file.");
|
||||
m.def("get_info_fileobj", &paddleaudio::sox_io::get_info_fileobj,
|
||||
"Get metadata of audio in file object.");
|
||||
}
|
@ -1,32 +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.
|
||||
|
||||
#ifndef PADDLEAUDIO_PYBIND_SOX_IO_H
|
||||
#define PADDLEAUDIO_PYBIND_SOX_IO_H
|
||||
|
||||
#include <paddleaudio/csrc/pybind/sox/utils.h>
|
||||
|
||||
namespace paddleaudio {
|
||||
namespace sox_io {
|
||||
|
||||
auto get_info_file(const std::string &path, const std::string &format)
|
||||
-> std::tuple<int64_t, int64_t, int64_t, int64_t, std::string>;
|
||||
|
||||
auto get_info_fileobj(py::object fileobj, const std::string &format)
|
||||
-> std::tuple<int64_t, int64_t, int64_t, int64_t, std::string>;
|
||||
|
||||
} // namespace paddleaudio
|
||||
} // namespace sox_io
|
||||
|
||||
#endif
|
Loading…
Reference in new issue