OPUS file code, how to open - audio

Hey I got the following file ( http://www.filedropper.com/opusfile )
Which is a .txt file containing OPUS audio code. How do I proceed and play this file?
Convertig to OPUS and using VLC player gives an error for me. Anyone with some tips?

Try renaming file with .opus or .ogg extension and open in VLC, Chrome, or Firefox.

Related

batch extraction of features - csv files not stored

I want to extract audio features from a large set of files using pyaudioanalysis, using the following command line (as suggested on the github project's page):
python3 audioAnalysis.py featureExtractionDir -i data/ -mw 1.0 -ms 1.0 -sw 0.050 -ss 0.050
This seems to indeed run the feature extraction - it takes time and return to prompt without error - but does not write any csv files.
Any hint about why this does not work would be greatly appreciated. Thank you.
Found the answer:
the files to be analyzed were actually ADPCM-compressed files, which apparently does not work. Therefore, this led to the following error (in the background, it was NOT returned, and only discovered while trying to run the command in a system call in R):
ValueError: Unknown wave file format: DVI_ADPCM. Supported formats: PCM, IEEE_FLOAT
Once files were uncompressed, the pyAudioAnalysis call worked as expected.

How to convert m3u8 file to mp4 video using nodeJS with a remote S3 input

The objective is to convert .m3u8 file(hls stream) to .mp4 video inside my NodeJS application. I've tried doing the same using ffmpeg on console and that works fine but unable to find a recently maintained package that helps me do this in node.
Also, my input file is not the usual file located in my local directory but a remote AWS S3 object URL which is otherwise accessible to all(public bucket), in simpler words,
How do I do ffmpeg -i https://mycloudfrontURL/myHLSfile.m3u8 output.mp4 in JS?
The best solution is to use ffmpeg directly in your node.js application.
Install ffmpeg on your pc. Then create a node.js file that runs ffmpeg like so:
const { execSync } = require('child_process')
const input = 'https://mycloudfrontURL/myHLSfile.m3u8'
const output = 'output.mp4'
execSync(`ffmpeg -y -i "${input}" "${output}"`)
You'll be able to execute ffmpeg and get the same result as if running it from the terminal. Make sure to have ffmpeg installed or indicate the full path if it doesn't work.
If this worked for you, upvote the solution.

Node.js: Converting MP4 to GIF (puppeteer-lottie)

I am trying to convert a .mp4 file to .gif using NPM packages, but nothing seems to be working.
I tried using gifski binary package (NPM) for this, but no luck. It says its a binary package and you can use it by child_process.spawn() or similar. I installed it with -g (global) flag and seems like its not recognized even with global flag. Not sure If you can set PATH or anything. Let me know if its possible.
As for the other tries, I used gify and its just not doing anything (no file or error).
I am getting the .mp4 file from puppeteer-lottie NPM package. Here's my code, if needed for testing:
const renderLottie = require('puppeteer-lottie');
await renderLottie({ animationData: data, output: 'example.mp4', width: 640 });
animationData: Sticker JSON
I am pretty sure that there are much easier ways to do this, but I am just using complex ones. I just want .mp4 to .gif at the end.
Thanks for your time.
For those of you who are still trying to find solution, I finally found it.
We just use ffmpeg with child_process.exec(). No need to install anything.
const { exec } = require("child_process");
exec("ffmpeg -i input.mp4 -qscale 0 output.gif");
input is your mp4 file that you want to convert, and output is your result gif file.
Source: Conrad Lotz's answer

nw.js node WebKit - unable to play audio file

I have started working with nw.js, creating a test app to play audio files from. I am working on OS X 10.11.
The code for the player is:
<audio id="audio_player" controls>
<source src="path/to/file/song.mp3" type="audio/mp3">
</audio>
The player and controls appear, but the file will not play. I have tried using a relative path, and an absolute path, trying both
"/path/to/file/song.mp3"
and
"file:///path/to/file/song.mp3"
schemes.
I have verified the path is valid in all cases.
This page:
http://docs.nwjs.io/en/latest/For%20Developers/Enable%20Proprietary%20Codecs/
tells me that mp3 should be supported (for v0.22.1+, though I haven't found a way to tell the version of my mp3, though is was made recently so I assume is the the latest codec.)
Just to try more stuff, I followed the instructions on these pages:
http://docs.nwjs.io/en/latest/For%20Developers/Enable%20Proprietary%20Codecs/
(It appears mp3 gained support since this doc came out.)
https://github.com/nwjs/nw.js/wiki/Using-MP3-%26-MP4-%28H.264%29-using-the--video--%26--audio--tags.
I downloaded the ffmpeg libs from here:
https://github.com/iteufel/nwjs-ffmpeg-prebuilt/releases
and placed copies here:
find . -name libffmpeg.dylib
./dist/nw.js-examples/osx64/nw.js-examples.app/Contents/Versions/67.0.3396.87/libffmpeg.dylib
./node_modules/nw/nwjs/nwjs.app/Contents/Versions/54.0.2840.99/nwjs Framework.framework/libffmpeg.dylib
./node_modules/nw-builder/cache/0.31.2-sdk/osx64/nwjs.app/Contents/Versions/67.0.3396.87/libffmpeg.dylib
cp ~/Downloads/libffmpeg.dylib ./dist/nw.js-examples/osx64/nw.js-examples.app/Contents/Versions/67.0.3396.87/libffmpeg.dylib
cp ~/Downloads/libffmpeg.dylib "./node_modules/nw/nwjs/nwjs.app/Contents/Versions/54.0.2840.99/nwjs Framework.framework/libffmpeg.dylib"
cp ~/Downloads/libffmpeg.dylib "./node_modules/nw-builder/cache/0.31.2-sdk/osx64/nwjs.app/Contents/Versions/67.0.3396.87/libffmpeg.dylib"
Still to no avail running either
npm run dev
or
npm run prod
and opening the packaged app.
I can play the file fine with the same code from a web browser.
I don't know what else to try, help would be much appreciated, thanks.

MPEG DASH:using Gpac to get MPD files

My goal is to convert some mpeg4 files in my hard disk into mpd files that will alllow me to use it in mpeg dash streaming .i read about gpac's MP4Box capability to create mpd files and i followed the instructions of the following link to successfully compile gpac for ubuntu like in the instructions in this two links
http://gpac.wp.mines-telecom.fr/2011/04/20/compiling-gpac-on-ubuntu/
http://gpac.wp.mines-telecom.fr/2012/02/01/dash-support/
But when i try to execute any command such as
MP4Box -dash 10000 -frag 1000 -rap myFile.mp4
I get the following error
Option -dash unknown. Please check usage
I wonder is there any commands or instructions that i must execute when building gpac to add the dash and if is there any other methods to get my own MPD File not those provided by itec.
Thanks in advance !!!
Try to follow the compile instruction carefully & make sure to fetch the latest version from SVN.
MP4Box should work with your commands.
looks like you are using a outdated version of MP4Box. try downloading and compiling the latest one from here (for me the same command works): http://gpac.wp.mines-telecom.fr/downloads/gpac-nightly-builds/

Resources