Skip to content

Commit

Permalink
Python release with RPI5 support (#57)
Browse files Browse the repository at this point in the history
  • Loading branch information
mrrostam authored Feb 6, 2024
1 parent d5e41dc commit 06042f5
Show file tree
Hide file tree
Showing 10 changed files with 62 additions and 33 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/python-demos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ jobs:

strategy:
matrix:
machine: [rpi3-32, rpi3-64, rpi4-32, rpi4-64, jetson]
machine: [rpi3-32, rpi3-64, rpi4-32, rpi4-64, rpi5-64, jetson]

steps:
- uses: actions/checkout@v3
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/python-perf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ jobs:
strategy:
fail-fast: false
matrix:
machine: [rpi3-32, rpi3-64, rpi4-32, rpi4-64, jetson]
machine: [rpi3-32, rpi3-64, rpi4-32, rpi4-64, rpi5-64, jetson]
include:
- machine: rpi3-32
proc_performance_threshold_sec: 2.5
Expand All @@ -90,6 +90,8 @@ jobs:
proc_performance_threshold_sec: 2.5
- machine: rpi4-64
proc_performance_threshold_sec: 2.5
- machine: rpi5-64
proc_performance_threshold_sec: 0.5
- machine: jetson
proc_performance_threshold_sec: 2.5

Expand Down
19 changes: 19 additions & 0 deletions .github/workflows/python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,3 +60,22 @@ jobs:

- name: Test
run: python test_koala.py --access-key ${{secrets.PV_VALID_ACCESS_KEY}}

build-self-hosted:
runs-on: ${{ matrix.machine }}

strategy:
matrix:
machine: [rpi3-32, rpi3-64, rpi4-32, rpi4-64, rpi5-64, jetson]

steps:
- uses: actions/checkout@v3

- name: Pre-build dependencies
run: python3 -m pip install --upgrade pip

- name: Install dependencies
run: pip install -r requirements.txt

- name: Test
run: python3 test_koala.py --access-key ${{secrets.PV_VALID_ACCESS_KEY}}
34 changes: 17 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,26 +14,26 @@ Koala is an on-device noise suppression engine. Koala is:
- Linux (x86_64), macOS (x86_64, arm64), Windows (x86_64)
- Android and iOS
- Chrome, Safari, Firefox, and Edge
- Raspberry Pi (4, 3) and NVIDIA Jetson Nano
- Raspberry Pi (5, 4, 3) and NVIDIA Jetson Nano

## Table of Contents

- [Koala](#koala)
- [Table of Contents](#table-of-contents)
- [AccessKey](#accesskey)
- [Demos](#demos)
- [Python](#python-demos)
- [Android](#android-demo)
- [iOS](#ios-demo)
- [C](#c-demos)
- [Web](#web-demo)
- [SDKs](#sdks)
- [Python](#python)
- [Android](#android)
- [iOS](#ios)
- [C](#c)
- [Web](#web)
- [Releases](#releases)
- [Table of Contents](#table-of-contents)
- [AccessKey](#accesskey)
- [Demos](#demos)
- [Python Demos](#python-demos)
- [Android Demo](#android-demo)
- [iOS Demo](#ios-demo)
- [C Demos](#c-demos)
- [Web Demo](#web-demo)
- [SDKs](#sdks)
- [Python](#python)
- [Android](#android)
- [iOS](#ios)
- [C](#c)
- [Web](#web)
- [Releases](#releases)

## AccessKey

Expand Down Expand Up @@ -324,4 +324,4 @@ Replace `${ACCESS_KEY}` with yours obtained from [Picovoice Console](https://con

### v1.0.0 - February 7th, 2023

- Initial release
- Initial release
6 changes: 3 additions & 3 deletions binding/python/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@ Koala is an on-device noise suppression engine. Koala is:
- Linux (x86_64), macOS (x86_64, arm64), Windows (x86_64)
- Android and iOS
- Chrome, Safari, Firefox, and Edge
- Raspberry Pi (4, 3) and NVIDIA Jetson Nano
- Raspberry Pi (5, 4, 3) and NVIDIA Jetson Nano

## Compatibility

- Python 3.5 or higher
- Runs on Linux (x86_64), macOS (x86_64, arm64), Windows (x86_64), Raspberry Pi (4, 3), and NVIDIA Jetson Nano.
- Python 3.7 or higher
- Runs on Linux (x86_64), macOS (x86_64, arm64), Windows (x86_64), Raspberry Pi (5, 4, 3), and NVIDIA Jetson Nano.

## Installation

Expand Down
10 changes: 9 additions & 1 deletion binding/python/_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,19 @@ def _linux_machine() -> str:
return 'cortex-a57' + arch_info
elif '0xd08' == cpu_part:
return 'cortex-a72' + arch_info
elif "0xd0b" == cpu_part:
return "cortex-a76" + arch_info
else:
raise NotImplementedError("Unsupported CPU: `%s`." % cpu_part)


_RASPBERRY_PI_MACHINES = {'cortex-a53', 'cortex-a72', 'cortex-a53-aarch64', 'cortex-a72-aarch64'}
_RASPBERRY_PI_MACHINES = {
"cortex-a53",
"cortex-a72",
"cortex-a76",
"cortex-a53-aarch64",
"cortex-a72-aarch64",
"cortex-a76-aarch64"}
_JETSON_MACHINES = {'cortex-a57-aarch64'}


Expand Down
4 changes: 2 additions & 2 deletions binding/python/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@

setuptools.setup(
name="pvkoala",
version="2.0.0",
version="2.0.1",
author="Picovoice",
author_email="[email protected]",
description="Koala Noise Suppression Engine.",
Expand All @@ -59,6 +59,6 @@
"Programming Language :: Python :: 3",
"Topic :: Multimedia :: Sound/Audio :: Speech"
],
python_requires='>=3.5',
python_requires='>=3.7',
keywords="Noise Cancellation, Noise Suppression, Noise Removal, Speech Enhancement, Speech Denoising",
)
6 changes: 3 additions & 3 deletions demo/python/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@ Koala is an on-device noise suppression engine. Koala is:
- Linux (x86_64), macOS (x86_64, arm64), Windows (x86_64)
- Android and iOS
- Chrome, Safari, Firefox, and Edge
- Raspberry Pi (4, 3) and NVIDIA Jetson Nano
- Raspberry Pi (5, 4, 3) and NVIDIA Jetson Nano

## Compatibility

- Python 3.5+
- Runs on Linux (x86_64), macOS (x86_64, arm64), Windows (x86_64), Raspberry Pi (4, 3), and NVIDIA Jetson Nano.
- Python 3.7+
- Runs on Linux (x86_64), macOS (x86_64, arm64), Windows (x86_64), Raspberry Pi (5, 4, 3), and NVIDIA Jetson Nano.

## Installation

Expand Down
4 changes: 2 additions & 2 deletions demo/python/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
pvkoala==2.0.0
pvrecorder==1.2.1
pvkoala==2.0.1
pvrecorder==1.2.2
6 changes: 3 additions & 3 deletions demo/python/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,15 @@

setuptools.setup(
name="pvkoalademo",
version="2.0.0",
version="2.0.1",
author="Picovoice",
author_email="[email protected]",
description="Koala Noise Suppression Engine demos",
long_description=long_description,
long_description_content_type="text/markdown",
url="https://github.com/Picovoice/koala",
packages=["pvkoalademo"],
install_requires=["pvkoala==2.0.0", "pvrecorder==1.2.1"],
install_requires=["pvkoala==2.0.1", "pvrecorder==1.2.2"],
include_package_data=True,
classifiers=[
"Development Status :: 5 - Production/Stable",
Expand All @@ -48,6 +48,6 @@
'koala_demo_mic=pvkoalademo.koala_demo_mic:main',
],
),
python_requires='>=3.5',
python_requires='>=3.7',
keywords="Noise Cancellation, Noise Suppression, Noise Removal, Speech Enhancement, Speech Denoising",
)

0 comments on commit 06042f5

Please sign in to comment.