ContentAutomation / TwitchCompilationCreator

A fully automated system that transforms Twitch clips into gaming compilations
https://github.com/ContentAutomation
MIT License
261 stars 29 forks source link

Error compiling footage #24

Closed ConnorServers closed 1 year ago

ConnorServers commented 1 year ago

`warning:root:No model for prediction available -> every clip is chosen as valid (ingame) info:root:Adding new valid clip: . by FaZeSway warning:root:No model for prediction available -> every clip is chosen as valid (ingame) info:root:Adding new valid clip: matrix movement by NateHill warning:root:No model for prediction available -> every clip is chosen as valid (ingame) info:root:Adding new valid clip: what is a junk rif? by TheNicoleT warning:root:No model for prediction available -> every clip is chosen as valid (ingame) info:root:Adding new valid clip: TRIO CASH CUP NO BUILD😎🤙 | -> KOD: KUBX <- | !keydrop !org !ppv by Kubx warning:root:No model for prediction available -> every clip is chosen as valid (ingame) info:root:Adding new valid clip: $100,000 SAMSUNG ODYSSEY TOURNAMENT W/ DAKOTAZ | !tourney !giveaway by xChocoBars info:root:Required length reached info:root:Saving metadata.json info:root:Loading metadata.json info:root:Refreshing Metadata info:root:Loading metadata_config.json info:root:Getting amount of playlist items warning:root:Status Code: 400, {'error': {'code': 400, 'message': 'API key not valid. Please pass a valid API key.', 'errors': [{'message': 'API key not valid. Please pass a valid API key.', 'domain': 'global', 'reason': 'badRequest'}], 'status': 'INVALID_ARGUMENT', 'details': [{'@type': 'type.googleapis.com/google.rpc.ErrorInfo', 'reason': 'API_KEY_INVALID', 'domain': 'googleapis.com', 'metadata': {'service': 'youtube.googleapis.com'}}]}} warning:root:Check if you inserted a correct PlayListID in your metadata_config -> return playlist_size of 0 info:root:Saving metadata.json info:root:Creating compilation from 13 clips Traceback (most recent call last): File "D:\Users\Connor\Desktop\TwitchBot.venv\lib\site-packages\moviepy\video\VideoClip.py", line 1137, in init subprocess_call(cmd, logger=None) File "D:\Users\Connor\Desktop\TwitchBot.venv\lib\site-packages\moviepy\tools.py", line 46, in subprocess_call proc = sp.Popen(cmd, **popen_params) File "C:\Users\Connor\AppData\Local\Programs\Python\Python310\lib\subprocess.py", line 966, in init self._execute_child(args, executable, preexec_fn, close_fds, File "C:\Users\Connor\AppData\Local\Programs\Python\Python310\lib\subprocess.py", line 1435, in _execute_child hp, ht, pid, tid = _winapi.CreateProcess(executable, args, FileNotFoundError: [WinError 2] The system cannot find the file specified

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "D:\Users\Connor\Desktop\TwitchBot\main.py", line 26, in vcc.create_compilation() File "D:\Users\Connor\Desktop\TwitchBot\src\ClipCompilationCreator.py", line 27, in create_compilation composite_clips = list(self.composite_clips(clips).values()) File "D:\Users\Connor\Desktop\TwitchBot\src\ClipCompilationCreator.py", line 70, in composite_clips txts = self.generate_clip_text(self.metadata) File "D:\Users\Connor\Desktop\TwitchBot\src\ClipCompilationCreator.py", line 87, in generate_clip_text txt = TextClip( File "D:\Users\Connor\Desktop\TwitchBot.venv\lib\site-packages\moviepy\video\VideoClip.py", line 1146, in init raise IOError(error) OSError: MoviePy Error: creation of None failed because of the following error:

[WinError 2] The system cannot find the file specified.

.This error can be due to the fact that ImageMagick is not installed on your computer, or (for Windows users) that you didn't specify the path to the ImageMagick binary in file conf.py, or that the path you specified is incorrect

(.venv) D:\Users\Connor\Desktop\TwitchBot> `

ChristianCoenen commented 1 year ago

Hey 👋 Did you go through this section of the README? It looks like you haven't installed ImageMagick yet.

ConnorServers commented 1 year ago

Hey mate.

My bad, I've installed it and added the 'PATH' to "C:\Program Files\ImageMagick-7.1.0-Q16-HDRI", however, returns this similar error.

`rors': [{'message': 'API key not valid. Please pass a valid API key.', 'domain': 'global', 'reason': 'badRequest'}], 'status': 'INVALID_ARGUMENT', 'details': [{'@type': 'type.googleapis.com/google.rpc.ErrorInfo', 'reason': 'API_KEY_INVALID', 'domain': 'googleapis.com', 'metadata': {'service': 'youtube.googleapis.com'}}]}} warning:root:Check if you inserted a correct PlayListID in your metadata_config -> return playlist_size of 0 info:root:Saving metadata.json info:root:Creating compilation from 13 clips Traceback (most recent call last): File "D:\Users\Connor\Desktop\TwitchBot.venv\lib\site-packages\moviepy\video\VideoClip.py", line 1137, in init subprocess_call(cmd, logger=None) File "D:\Users\Connor\Desktop\TwitchBot.venv\lib\site-packages\moviepy\tools.py", line 46, in subprocess_call proc = sp.Popen(cmd, **popen_params) File "C:\Users\Connor\AppData\Local\Programs\Python\Python310\lib\subprocess.py", line 966, in init self._execute_child(args, executable, preexec_fn, close_fds, File "C:\Users\Connor\AppData\Local\Programs\Python\Python310\lib\subprocess.py", line 1435, in _execute_child hp, ht, pid, tid = _winapi.CreateProcess(executable, args, FileNotFoundError: [WinError 2] The system cannot find the file specified

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "D:\Users\Connor\Desktop\TwitchBot\main.py", line 26, in vcc.create_compilation() File "D:\Users\Connor\Desktop\TwitchBot\src\ClipCompilationCreator.py", line 27, in create_compilation composite_clips = list(self.composite_clips(clips).values()) File "D:\Users\Connor\Desktop\TwitchBot\src\ClipCompilationCreator.py", line 70, in composite_clips txts = self.generate_clip_text(self.metadata) File "D:\Users\Connor\Desktop\TwitchBot\src\ClipCompilationCreator.py", line 87, in generate_clip_text txt = TextClip( File "D:\Users\Connor\Desktop\TwitchBot.venv\lib\site-packages\moviepy\video\VideoClip.py", line 1146, in init raise IOError(error) OSError: MoviePy Error: creation of None failed because of the following error:

[WinError 2] The system cannot find the file specified.

.This error can be due to the fact that ImageMagick is not installed on your computer, or (for Windows users) that you didn't specify the path to the ImageMagick binary in file conf.py, or that the path you specified is incorrect`

ChristianCoenen commented 1 year ago

I think the path needs to be "C:\Program Files\ImageMagick-7.1.0-Q16-HDRI\magick.exe". Also, you might need to use double backslashes. Try to restart your IDE between every try to ensure the path update is propagated to your IDE.

Let me know if it still doesn't work. @lucaSchilling might be able to help you since he used to set it up on Windows (I don't have a Windows system close by)