Comments (7)
Hi Patrick,
Did you follow all the directions in the Installation part of the Readme, including creating and activating a virtual Python environment?
My guess would be you haven't run the command pip install -r requirements.txt
. This should install all the required Python modules, including keyboard
.
Please let me know if you have followed all the directions and run all the commands and are still encountering this issue. If that's the case, please also let me know what platform you are running WhisperWriter on and which version of Python you are using.
Thanks,
Sav
from whisper-writer.
Hi Savbell,
Thanks for your answer.
I've been trough all installation procedure.
When running pip install -r requirements.txt, an error occured :
ERROR: Cannot install -r requirements.txt (line 14) and av==10.0.0 because these package versions have conflicting dependencies.
The conflict is caused by:
The user requested av==10.0.0
faster-whisper 0.10.0 depends on av==11.*
Any suggestion ? thanks, patrick
Ubuntu 22.04
from whisper-writer.
Hi Patrick,
Thanks for your response! What you're encountering is an error that has since been fixed in the latest commits. Try running git pull
to update requirements.txt
to the latest version (it should look like this, with av==11.0.0
on line 8). Then try running pip install -r requirements.txt
again and let me know if that works!
Cheers,
Sav
from whisper-writer.
Hi Sav,
thanks for your help.
Pip install -r requirements.txt report this warning :
WARNING: Generating metadata for package evdev produced metadata for project name unknown. Fix your #egg=evdev fragments.
Discarding https://files.pythonhosted.org/packages/12/bb/f622a8a5e64d46ca83020a761877c0ead19140903c9aaf1431f3c531fdf6/evdev-1.7.1.tar.gz#sha256=0c72c370bda29d857e188d931019c32651a9c1ea977c08c8d939b1ced1637fde (from https://pypi.org/simple/evdev/) (requires-python:>=3.6): Requested unknown from https://files.pythonhosted.org/packages/12/bb/f622a8a5e64d46ca83020a761877c0ead19140903c9aaf1431f3c531fdf6/evdev-1.7.1.tar.gz#sha256=0c72c370bda29d857e188d931019c32651a9c1ea977c08c8d939b1ced1637fde (from pynput==1.7.6->-r requirements.txt (line 53)) has inconsistent name: filename has 'evdev', but metadata has 'unknown'
Downloading evdev-1.7.0.tar.gz (30 kB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Installing backend dependencies ... done
Preparing metadata (pyproject.toml) ... done
WARNING: Generating metadata for package evdev produced metadata for project name unknown. Fix your #egg=evdev fragments.
Discarding https://files.pythonhosted.org/packages/f3/0c/c87b141250a650ee53d4e9957e905b17c144cda6dc4187cbe89a641a1b34/evdev-1.7.0.tar.gz#sha256=95bd2a1e0c6ce2cd7a2ecc6e6cd9736ff794b3ad5cb54d81d8cbc2e414d0b870 (from https://pypi.org/simple/evdev/) (requires-python:>=3.6): Requested unknown from https://files.pythonhosted.org/packages/f3/0c/c87b141250a650ee53d4e9957e905b17c144cda6dc4187cbe89a641a1b34/evdev-1.7.0.tar.gz#sha256=95bd2a1e0c6ce2cd7a2ecc6e6cd9736ff794b3ad5cb54d81d8cbc2e414d0b870 (from pynput==1.7.6->-r requirements.txt (line 53)) has inconsistent name: filename has 'evdev', but metadata has 'unknown'
Downloading evdev-1.6.1.tar.gz (26 kB)
Preparing metadata (setup.py) ... done
Then when running python3 run.py
Starting WhisperWriter...
Traceback (most recent call last):
File "/home/pv/whisper-writer/src/main.py", line 9, in
from transcription import create_local_model, record_and_transcribe
File "/home/pv/whisper-writer/src/transcription.py", line 4, in
import sounddevice as sd
File "/home/pv/.local/lib/python3.10/site-packages/sounddevice.py", line 71, in
raise OSError('PortAudio library not found')
OSError: PortAudio library not found
Sorry not to be able to understand these.
Any idea to sole it ?
thanks, patrick
from whisper-writer.
Hi Patrick,
It looks like the error is indicating the PortAudio library is either not installed or can't be found. You can try installing the PortAudio development package:
sudo apt update
sudo apt install libportaudio2 libportaudiocpp0 portaudio19-dev
And then reinstalling sounddevice
:
pip uninstall sounddevice
pip install sounddevice
Hopefully that resolves your issue! Please let me know if it doesn't.
Thanks,
Sav
from whisper-writer.
Hi Sav,
I encounter this error after pip install -r requirements.txt :
Using cached lit-18.1.4-py3-none-any.whl (96 kB)
Building wheels for collected packages: evdev
Building wheel for evdev (pyproject.toml) ... error
error: subprocess-exited-with-error
× Building wheel for evdev (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [40 lines of output]
running bdist_wheel
running build
running build_py
creating build
creating build/lib.linux-x86_64-cpython-311
creating build/lib.linux-x86_64-cpython-311/evdev
copying evdev/events.py -> build/lib.linux-x86_64-cpython-311/evdev
copying evdev/eventio_async.py -> build/lib.linux-x86_64-cpython-311/evdev
copying evdev/util.py -> build/lib.linux-x86_64-cpython-311/evdev
copying evdev/device.py -> build/lib.linux-x86_64-cpython-311/evdev
copying evdev/ff.py -> build/lib.linux-x86_64-cpython-311/evdev
copying evdev/eventio.py -> build/lib.linux-x86_64-cpython-311/evdev
copying evdev/ecodes.py -> build/lib.linux-x86_64-cpython-311/evdev
copying evdev/init.py -> build/lib.linux-x86_64-cpython-311/evdev
copying evdev/evtest.py -> build/lib.linux-x86_64-cpython-311/evdev
copying evdev/genecodes.py -> build/lib.linux-x86_64-cpython-311/evdev
copying evdev/uinput.py -> build/lib.linux-x86_64-cpython-311/evdev
running egg_info
writing evdev.egg-info/PKG-INFO
writing dependency_links to evdev.egg-info/dependency_links.txt
writing top-level names to evdev.egg-info/top_level.txt
reading manifest file 'evdev.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no previously-included files found matching 'evdev/ecodes.c'
adding license file 'LICENSE'
writing manifest file 'evdev.egg-info/SOURCES.txt'
copying evdev/input.c -> build/lib.linux-x86_64-cpython-311/evdev
copying evdev/uinput.c -> build/lib.linux-x86_64-cpython-311/evdev
running build_ext
running build_ecodes
writing /tmp/pip-install-5zq7t9ic/evdev_874eb02d26c04a93a07de4a82f4080e3/evdev/ecodes.c (using /usr/include/linux/input.h /usr/include/linux/input-event-codes.h /usr/include/linux/uinput.h)
building 'evdev._input' extension
creating build/temp.linux-x86_64-cpython-311
creating build/temp.linux-x86_64-cpython-311/evdev
x86_64-linux-gnu-gcc -Wsign-compare -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -g -fwrapv -O2 -fPIC -I/home/pv/whisper-writer/venv/include -I/usr/include/python3.11 -c evdev/input.c -o build/temp.linux-x86_64-cpython-311/evdev/input.o -std=c99 -Wno-error=declaration-after-statement
evdev/input.c:10:10: fatal error: Python.h: Aucun fichier ou dossier de ce nom
10 | #include <Python.h>
| ^~~~~~~~~~
compilation terminated.
error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for evdev
Failed to build evdev
ERROR: Could not build wheels for evdev, which is required to install pyproject.toml-based projects
Thanks for any suggestion,
patrick
from whisper-writer.
Hi Patrick,
I'm sorry you're running into so many errors trying to install the packages! This error seems to be due to a missing Python.h
header file. It may not be installed on your system, in which case the solution would be to install the Python development headers:
sudo apt-get install python3-dev
And then you can try installing the packages again. I hope that helps!
Cheers,
Sav
from whisper-writer.
Related Issues (20)
- initial_prompt doesn't seem to be working HOT 2
- Doesn't work with API HOT 1
- Feature request: use shortcut to end recording HOT 6
- Seeming to pull erroneous OpenAI API key - different from what I set and verify in .env HOT 1
- Requirements incomplete and device detection does not work properly HOT 1
- Push to talk implementation
- Doesn't seem to support German special characters (Umlaute) like ä, ü, ö, ß HOT 5
- Need conversion of sample rate
- Could not load library cudnn_ops_infer64_8.dll. (Windows) HOT 4
- Please add support for local whisper api HOT 2
- CUDA requirements need to match project dependencies. Distribute the libraries? HOT 2
- Detect input language each time the hold_to_record shortcut is pressed
- Doesn't work for longer recordings using press_to_toggle
- Immediately abort typing when active window changed HOT 1
- nixkeyboard.py: You must be root to use this library on linux... HOT 1
- New features: Automatically start and stop to record. Bip sound once text is insert. HOT 2
- "You must be root" HOT 1
- Missing requirements: pycairo PyGObject HOT 1
- Program Not Responsive after a few minutes; Require Restart HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from whisper-writer.