Questions tagged [pydub]

Pydub is a Python library for audio manipulation.

Pydub is a Python library for manipulating audio.

Quick links:

427 questions
0
votes
0 answers

How can I convert SD2 to WAV? Would Python, FFmpeg or shell based sd2 audio file converters work?

I have 3TBs+ of sd2 (Sound Designer II) files that I need to convert to wave files. I had hoped to write a simple script to go through all the folders recursively (this I have no issues with - it is the conversion). I am not sure if a codec can be…
tzujan
  • 186
  • 1
  • 10
0
votes
1 answer

Overlay wav files at different start times using Pydub

I have a series of wav files I would like to combine and export as a single wav using Pydub. I would like the audio from the original files to play back at different times in the exported file e.g. the audio in audio_1.wav starts at time=0 in the…
John
  • 40
  • 4
0
votes
3 answers

Combining wav files programmatically - Python

I am looking to combine 10 audio samples in various manners (format - wav probably, but this can be changed to any format as they will be pre-recorded). from pydub import AudioSegment sounds = [] sound1 =…
NimueSTEM
  • 193
  • 2
  • 13
0
votes
0 answers

How to set a fix volume throughout an audio file using Python

I've some audio clips each around 5 minutes long. Within each audio file, 2 people are talking, where some part is loud (when person 1 is talking) while some part is very low (difficult to hear, while person 2 is talking). I've tried using #pydub,…
0
votes
0 answers

im trying to use pydub with discord.py, but no audio is coming out

I'm trying to use pydub with discord.py, as pydub has features that i wanna add to my discord bot. However, i can't hear any audio coming out from the bot, and there are no error messages. What do i do? here is my code: @bot.command(name='playtest',…
sunatdoc
  • 21
  • 2
0
votes
0 answers

Is there a way i could use an audio api like pydub with discord.py?

I'm trying to make a discord bot that could do simple commands like looping an mp3 seamlessly and adding stems on top of each other, like in a DAW. I want to do all this using pydub and play the audio through the discord vc, is it possible?
sunatdoc
  • 21
  • 2
0
votes
0 answers

Can't make .wav louder/quieter using pydub

I made a code to take a .mp3 archive path, transforms it into .wav and make this archive louder or quieter depending on the user's choice. Here's the code: import sys import os from os import path from pydub import AudioSegment input_file =…
Kodora
  • 1
  • 1
0
votes
1 answer

Merging mp3s into one in Python

I have read on SOverflow to use PyDub for this, but PyDub doesn't seem to be working in Python 3.9. This is my code from pydub import AudioSegment firstfile = AudioSegment.from_mp3(r'C:/Users/ogiga/Desktop/Nice/FinalVideo.mp3') But I keep getting…
0
votes
1 answer

Converting wav to wav ulaw from Python

Trying to convert a wav file to a wav uLaw in python. Using pydub's AudioSegment I am able to convert to mp3 using the following : AudioSegment.from_wav(fromFile).export(toFile, format="mp3", bitrate="128k") What would be the equivalent for wav…
Powlow
  • 1
  • 5
0
votes
0 answers

Pydub to bluetooth speaker doesn't work when under a subprocess call

I have a simple code that I want to execute that links my raspberry pi4 to a bluetooth speaker. It works as it is, but when I link it to a a subprocess call, there is no sound. #!/usr/bin/python3 from pydub import AudioSegment from pydub.playback…
k3nz3n
  • 1
0
votes
1 answer

How do I get number of frames from the m4a file?

I want to open the m4a audio file for analysis but I am getting this error. File "E:\audio stego\code.py", line 5, in song = AudioSegment.from_file('E:\\audio stego\\03 VALNDALUM UMMODU.m4a') File…
0
votes
0 answers

Pydub send raw data to icecast server

Well, this code works: with requests.get("https://impradio.bytemasters.gr/8002/LIVE", stream=True) as peradio: for chunk in peradio.iter_content(chunk_size=4096): self.s.send(chunk) self.s.sync() but this…
Chris P
  • 2,059
  • 4
  • 34
  • 68
0
votes
1 answer

Pydub opens fmpeg consoles in exe (pyinstaller)

Trying to make an exe. The project uses a lot of packages, such as pydub. I think that pydub in .exe opens the ffmpeg console. How can I prevent PyQt5 app to show cmd windows? Edit: Check out the video to see what I mean:…
Chris P
  • 2,059
  • 4
  • 34
  • 68
0
votes
1 answer

Can't convert mp3 with Python 3.9

I've been trying to convert a MP3 file to an OGG one, but I keep getting this error message: C:\Users\Administrador\AppData\Local\Programs\Python\Python39\lib\site- File "c:\Users\Administrador\Desktop\Codigo python\boludez.py", line 5, in…
Oto
  • 121
  • 5
0
votes
1 answer

Errors while using PyDub. How do I fix?

I am trying to make a DAW, but I keep getting the same error whenever I try to run the code. Also my file cannot be found, even though I put in the right path. Code: import getpass from pydub import…
waisinz
  • 5
  • 2