Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ffmpeg had status 69 when creating any spectrogram video #22

Open
conormcmahon opened this issue Oct 25, 2024 · 5 comments
Open

ffmpeg had status 69 when creating any spectrogram video #22

conormcmahon opened this issue Oct 25, 2024 · 5 comments

Comments

@conormcmahon
Copy link

Awesome package, I've been looking for something like this for a while! I'd love to have a working installation for several different bioacoustic projects. But I'm having issues getting spectrograms to output with any video content.

Currently, when I create a spectrogram using the example scripts here, the code runs for about a minute and then outputs a .mp4 file, but it only includes the audio, no video content.

When it finishes executing, it outputs this warning, which I find a little opaque:

Warning message:
In system(cll1, intern = TRUE, ignore.stdout = TRUE, ignore.stderr = TRUE) :
  running command 'ffmpeg -framerate 50 -i C:\Users\grad\AppData\Local\Temp\RtmpQdtuNO/%05d.temp.img.tiff -c:v libx264 -profile:v high -crf 2 -pix_fmt yuv420p -y C:\Users\grad\AppData\Local\Temp\RtmpQdtuNO/scroll.spectro.temp.mp4' had status 69

I'm working on a Windows 10 machine and running R in Rstudio. I've installed ffmpeg and added it to the system path and tested that it's accessible to a command prompt. I thought the issue might be with my ffmpeg version, so I've tried two with the same result:

' ffmpeg-git-full.7z ' from here

' ffmpeg-master-latest-win64-gpl.zip ' from https://github.com/BtbN/FFmpeg-Builds/releases

But in either case get the same warning and the same behavior writing a .mp4 file with only audio. I also tried outputting to .mov with the same result.

I've tried updating tuneR, seewave, and tidyverse in case there was some weird dependence issue. Is there anything else I can try?

Thanks again for writing a really useful package!

@conormcmahon
Copy link
Author

Also, I installed dynaSpec using the CRAN installation

install.packages("dynaSpec")

@conormcmahon
Copy link
Author

Here are example files output from the Canyon Wren data following the code on the example page.

default.mov
default.mp4

@conormcmahon
Copy link
Author

For what it's worth, I just tried this on another Windows machine with a fresh R version (4.4.1) where I only installed tidyverse, seewave, tuneR, warbleR, viridis, and dynaSpec (all from CRAN using install.packages() ) and have the same result.

@conormcmahon
Copy link
Author

I was able to get the Google Collab notebook version to work (although had to add a line to load warbleR to use the read_sound_file() function and uncomment loading viridis vs. the stock version of the notebook). So I'm wondering if my issues on Windows are related to some of the other system dependencies outside of R, like fftw3, libsndfile1, etc.

For now I'm trying to get a version working in WSL within windows but currently running into some annoying dependency issues related to my sf installation (which I'm using elsewhere for other things and am trying to avoid messing with).

@maRce10
Copy link
Owner

maRce10 commented Oct 31, 2024

HI Conor, it has always been difficult to make it run on windows. That's why I decided to share the google colab. It used to work on previous windows versions but there seems to be a new issue every new version. I fixed the issue with the google colab.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants