Skip to content

Commit f6e8903

Browse files
committed
requirements file added
1 parent 3cef83d commit f6e8903

File tree

3 files changed

+14
-11
lines changed

3 files changed

+14
-11
lines changed

Dockerfile

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ COPY . /root/ros2_ws/src
99
# Install dependencies
1010
RUN apt-get update
1111
RUN rosdep update --include-eol-distros && rosdep install --from-paths src --ignore-src -r -y
12+
RUN pip3 install -r requirements.txt
1213

1314
WORKDIR /root/ros2_ws/src
1415
RUN git clone https://github.com/mgonzs13/audio_common.git

README.md

+12-11
Original file line numberDiff line numberDiff line change
@@ -33,46 +33,47 @@ This repository provides a set of ROS 2 packages to integrate [whisper.cpp](http
3333
To run whisper_ros with CUDA, first, you must install the [CUDA Toolkit](https://developer.nvidia.com/cuda-toolkit).
3434

3535
```shell
36-
$ cd ~/ros2_ws/src
37-
$ git clone https://github.com/mgonzs13/audio_common.git
38-
$ git clone https://github.com/mgonzs13/whisper_ros.git
39-
$ cd ~/ros2_ws
40-
$ rosdep install --from-paths src --ignore-src -r -y
41-
$ colcon build --cmake-args -DGGML_CUDA=ON # add this for CUDA
36+
cd ~/ros2_ws/src
37+
git clone https://github.com/mgonzs13/audio_common.git
38+
git clone https://github.com/mgonzs13/whisper_ros.git
39+
pip3 install -r whisper_ros/requirements.txt
40+
cd ~/ros2_ws
41+
rosdep install --from-paths src --ignore-src -r -y
42+
colcon build --cmake-args -DGGML_CUDA=ON # add this for CUDA
4243
```
4344

4445
## Docker
4546

4647
Build the whisper_ros docker. Additionally, you can choose to build whisper_ros with CUDA (`USE_CUDA`) and choose the CUDA version (`CUDA_VERSION`). Remember that you have to use `DOCKER_BUILDKIT=0` to compile whisper_ros with CUDA when building the image.
4748

4849
```shell
49-
$ DOCKER_BUILDKIT=0 docker build -t whisper_ros --build-arg USE_CUDA=1 --build-arg CUDA_VERSION=12-6 .
50+
DOCKER_BUILDKIT=0 docker build -t whisper_ros --build-arg USE_CUDA=1 --build-arg CUDA_VERSION=12-6 .
5051
```
5152

5253
Run the docker container. If you want to use CUDA, you have to install the [NVIDIA Container Tollkit](https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/latest/install-guide.html) and add `--gpus all`.
5354

5455
```shell
55-
$ docker run -it --rm --gpus all whisper_ros
56+
docker run -it --rm --gpus all whisper_ros
5657
```
5758

5859
## Usage
5960

6061
Run Silero for VAD and Whisper for STT:
6162

6263
```shell
63-
$ ros2 launch whisper_bringup whisper.launch.py
64+
ros2 launch whisper_bringup whisper.launch.py
6465
```
6566

6667
## Demos
6768

6869
Send a goal action to listen:
6970

7071
```shell
71-
$ ros2 action send_goal /whisper/listen whisper_msgs/action/STT "{}"
72+
ros2 action send_goal /whisper/listen whisper_msgs/action/STT "{}"
7273
```
7374

7475
Or try the example of a whisper client:
7576

7677
```shell
77-
$ ros2 run whisper_demos whisper_demo_node
78+
ros2 run whisper_demos whisper_demo_node
7879
```

requirements.txt

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
huggingface-hub==0.23.4

0 commit comments

Comments
 (0)