from mmagic.apis import MMagicInferencer
editor = MMagicInferencer(model_name='controlnet_animation')
prompt = 'a girl, black hair, T-shirt, smoking, best quality, extremely detailed'
negative_prompt = 'longbody, lowres, bad anatomy, bad hands, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality'
video = '../run_forrest_frames_rename_resized.mp4'
save_path = '../output_video.mp4'
editor.infer(video=video, prompt=prompt, image_width=512, image_height=512, negative_prompt=negative_prompt, save_path=save_path)
剪贴板-用于将生成的URL自动复制到剪贴板
File :: MMagic-用于检测和设置正确的MIME类型,否则使用application/data 。
UUID :: Tiny-用于生成路径的UUID,否则使用随机字符串。
URI :: Escape-如果文件名中包含不安全的字符,则使用URI :: Escape会对它们进行转义,否则,otfile将死于错误。
$ curl -O https://raw.github.com/mikegrb/One-Time-File/master/script/otfile
$ # or
$ wget https://raw.github.com/mikegrb/One-Time-File/m