dmarx / video-killed-the-radio-star

Notebook and tools for end-to-end automation of music video production with generative AI
https://colab.research.google.com/github/dmarx/video-killed-the-radio-star/blob/main/Video_Killed_The_Radio_Star_Defusion.ipynb#scrollTo=oPbeyWtesAoh
MIT License
198 stars 35 forks source link

audio_fpath: no direction on how to upload file or sample path #113

Closed hannahedeen closed 1 year ago

hannahedeen commented 1 year ago

when using the tool I am not sure what path configuration to use and what is considered the "root" directory. I have linked my google drive and tried putting the audio file in the notebook, but that also doesnt work.

For sure could be user error. Trying to get some direction.

hannahedeen commented 1 year ago

exact failure


---------------------------------------------------------------------------
ValueError                                Traceback (most recent call last)
[<ipython-input-2-743d9a5d85ed>](https://localhost:8080/#) in <module>
    129     # estimate duration from audio file
    130     audio_fpath = storyboard.params['audio_fpath']
--> 131     storyboard.params['video_duration'] = get_audio_duration_seconds(audio_fpath)
    132 
    133 if storyboard.params.get('video_duration') is None:

[/usr/local/lib/python3.9/dist-packages/vktrs/utils.py](https://localhost:8080/#) in get_audio_duration_seconds(audio_fpath)
     40         stdout=subprocess.PIPE
     41         ).stdout.decode('utf-8')
---> 42     return float(outv.strip())
     43 
     44 

ValueError: could not convert string to float: ''
H2whoaMusic commented 1 year ago

For what it's worth, I never found a way to get it to handle audio files saved on my Google Drive, even though the notebook has access to it. I ended up having a hidden page on my website where I upload MP3 files so that I can then link to that.

Edited to add: though I have just found this, which may resolve the problem by converting the sharing link to a direct download link: https://sites.google.com/site/gdocs2direct/

hannahedeen commented 1 year ago

Using the direct download link worked! thanks :)