Git Product home page Git Product logo

Comments (6)

GarrettHartley avatar GarrettHartley commented on July 28, 2024 1

$ pip freeze
cffi==1.5.2
Pillow==3.1.1
PyAudio==0.2.9
pycparser==2.14
sounddevice==0.3.2

I show all of the above modules installed, using pip freeze, but I still get this same error

import sounddevice as sd
The error:
ImportError: No module name sounddevice

from python-sounddevice.

mgeier avatar mgeier commented on July 28, 2024

Do you have different Python versions installed?

If yes, you have to install the module on each of them.

Or probably your "independent python program" uses a virtual environment?

from python-sounddevice.

TonderaiZR avatar TonderaiZR commented on July 28, 2024

Hello I solved the problem by removing --user when installing with pip. So the install command will be pip install sounddevice without --user.

from python-sounddevice.

mgeier avatar mgeier commented on July 28, 2024

@tondy That's strange, it should work with the --user option.

Did you install the library with the same user account as you are using it later?
Did you happen to use sudo in any of the commands?

The reason for the --user option is that you don't need sudo (or the root password) at all.

@GarrettHartley note that you may have different versions of pip installed. You may also have pip3 or pip-3.5 or similar.

To make sure to use the correct Python version for pip-installing, you can also use:

python3 -m pip install sounddevice

from python-sounddevice.

GarrettHartley avatar GarrettHartley commented on July 28, 2024

I got it to work by including '#!/usr/bin/env python3' at the top of my file. Sorry this was sorta a silly issue.

from python-sounddevice.

mgeier avatar mgeier commented on July 28, 2024

@GarrettHartley No problem, I know it can be confusing to handle those different versions. I'm glad that it works now for you.

@tondy Any news from your side?

from python-sounddevice.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.