I have successfully installed openSMILE for extracting features of a wav file (audio).
SMILExtract -C config/chroma_fft.sum.conf -I input.wav -O chroma.csv
I have successfully used this cmdline (I am using Windows 10) command to extract the features of a single audio file.
Now I want to compute features of multiple files at once using OpenSmile, rather than feeding 1000s of filenames and then concatenating the resultant CSV.
Any help here would be appreciated.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed last year.
The community reviewed whether to reopen this question 8 months ago and left it closed:
Original close reason(s) were not resolved
Improve this question
I have many webp format images in a folder but with .jpg extension like
abc-test.jpg
It's a webp format image. I want it to convert in .png format with same name for that I have used this command and it worked
find . -name "*.jpg" -exec dwebp {} -o {}.png \;
It converted all webp images to .png but the issue is it's saving images like this:
abc-test.jpg.png
But my requirement is to save it without .jpg extension like
abc-test.png
If you have many to convert/rename, I would recommend you use GNU Parallel and not only get them converted faster by doing them I parallel, but also take advantage of the ability to modify filenames.
The command you want is:
parallel dwebp {} -o {.}.png ::: *.jpg
where the {.} means "the filename without the original extension".
If you want to recurse into subdirectories too, you can use:
find . -name "*.jpg" -print0 | parallel -0 dwebp {} -o {.}.png
If you want a progress meter, or an "estimated time of arrival", you can add --progress or --eta after the parallel command.
If you want to see what GNU Parallel would run, without actually running anything, add --dry-run.
I commend GNU Parallel to you in this age where CPUs are getting "fatter" (more cores) rather than faster.
How to convert .webp images to .png on Linux
Tested on Linux Ubuntu 20.04
This question is the top hit for the Google search of "linux convert .webp image to png". Therefore, for anyone stumbling here and just wanting that simple answer, here it is:
# 1. Install the `webp` tool
sudo apt update
sudo apt install webp
# 2. Use it: convert in.webp to out.png
dwebp in.webp -o out.png
Done! You now have out.png.
References
I learned about dwebp from the question itself
I did it with short oneliner that does not require parallel to be installed in the system
for x in `ls -1 *.jpg`; do dwebp {} -o ${x%.*}.png ::: $x; done
And this works for current directory
I would try to amend the #mark-setchell recursive solution so it would look like this:
for x in `find . -name "*.jpg"`; do dwebp {} -o ${x%.*}.png ::: $x; done
The ${x%.*} part is the one requiring a word of explanation here - it tells bash to take . and everything after the dot from the x variable.
It is prone to misbehave for names with more dots as I did not check if regex here is lazy or greedy - the answer can be tuned further therefore.
If the problem is with linux image viewers - thats the reason of convertion - then I found that: here
"Add WebP support to GNOME Image Viewer in Ubuntu and Other Linux
By default, the photo viewer does not support WebP images files. However, you can add WebP support by installing webp-pixbuf-loader library. Not only it allows you to open WebP files in GNOME Image Viewer, it also displays thumbnails for WebP files in the file explorer.
On Ubuntu-based Linux distributions, you can install this library using a PPA. Use the following commands one by one:"
sudo add-apt-repository ppa:krifa75/eog-ordissimo
sudo apt update
sudo apt install webp-pixbuf-loader
A good thing to do is to use sed along with mv. It matches the pattern and replaces with a newer one.
for file in *.jpg;
do
mv "$file" "`echo $file | sed s/.jpg/.png/`"
done
if you want to retain the old files instead of mv you can use cp
I am trying to compress an audio file and I use -y command to overwrite the existing file. But problem is that that command decreases the duration of the audio file.
I am using the following command:
ffmpeg -y -i D:\audio\Blues.mp3 -ab 64 D:\audio\Blues.mp3
Is there any way to resolve this within ffmpeg? Thanks.
You can't read from a file and write to it at the same time with FFmpeg.
Write to a different file, then delete the original afterwards.
I created a nodejs application hosted on heroku which uses imagemagick. I am doing this operation:
require('child_process').exec(`convert -quiet -delay 1 output.avi ${gif}`);
This should convert output.avi (which is present) to a gif file. In this case, gif is "/app/temp/gifs/xstrycatdq.gif". This command works perfectly on my local windows machine. As I use the path module to get a variable with path.joinand __dirname.
I have installed heroku buildpack:
https://github.com/ello/heroku-buildpack-imagemagick
The error I am receiving is:
Command failed: convert -quiet -delay 1 output.avi /app/temp/gifs/xstrycatdq.gif
convert: DelegateFailed `'ffmpeg' -nostdin -v -1 -vframes %S -i '%i' -vcodec pam -an -f rawvideo -y '%u.pam' 2> '%Z'' # error/delegate.c/InvokeDelegate/1919.
convert: UnableToOpenBlob `magick-93R4VJcemPz0z1.pam': No such file or directory # error/blob.c/OpenBlob/2705.
convert: NoImagesDefined `/app/temp/gifs/xstrycatdq.gif' # error/convert.c/ConvertImageCommand/3257.
It seems that the /tmp/ directory can't be written to or anything. I also tried to mkdir /tmp/ but bash tells me that this dir already exists.
I have also tried changing the imagemagick's temp directory with the environment variable by doing export MAGICK_TMPDIR="temp".
Any help?
Edit: The variables are now absolute.
Are you sure it's not an issue of permissions? Can you write a simple text file to /app/temp? Is nothing is being read or written at all, it sounds like an issue of permissions. Maybe it's not necessarily a protection design of ImageMagick, but rather heroku or your programming environment?
This directory you're trying to use, it's special in that it contains corrupt or incomplete files - it may have special protections or guards in place, when certain software is running. temp directories are typically designed (or assumed) to be protected from user interference, as they are only to be used and worked with, by the program itself - not the user's commands of the program.
This question is similar to yours, it might be able to help you.
i'm trying to use SOX to cut certain mp3s, convert them to different formats and add fade in-out to the files.
It works fine with mp3 to mp3 but when i try to convert it from an MP3 to an m4r i get the error: "sox FAIL formats: no handler for file extension `m4r'".
I'm using SOX in windows so how can i install the ffmpeg package on top of the SOX so it knows waht to do with the m4r format?
on the same machine i can use ffmpeg to convert from mp3 to m4r just fine. It sucks that ffmpeg doesn't offer FADE for audio.
You may download and install ffmpeg library for audacity and then copy avcodec-52.dll avformat-52.dll avutil-50.dll swscale-0.dll to sox installation directory. Thus you can use sox as :
sox -t ffmpeg youFile.wma yourFile.wav