<jupyter_start><jupyter_text>waiting for about six and a half minutes after running the following cell...or just ignore the following cell, display the result directly.<jupyter_code>class TaskImageVideo():
    def __init__(self):
        self.ImageInput = '..\\..\\Output\\'
        self.ImageOutput = '..\\..\\Output\\renamed\\'
        self.VideoOutput = '..\\..\\Output\\video\\'
        self.VideoName = 'result'
        self.ffmpegPath = 'D:\\FFmpeg\\ffmpeg\\bin\\ffmpeg.exe'
        
    def Rename(self):
        f_list = os.listdir(self.ImageInput)
        image_list = []
        for filename in f_list:
            if os.path.splitext(filename)[1] == '.png':
                image_list.append(filename)
        for i in range(len(image_list)):
            img = Image.open(self.ImageInput + image_list[i])
            output_name = self.ImageOutput + 'image' + '_%03i.png' % (i)
            img.save(output_name)
            
    def Png2Jpg(self):
        f_list = os.listdir(self.ImageOutput)
        for filename in f_list:
            if os.path.splitext(filename)[1] == '.png':
                img = Image.open(self.ImageOutput + filename)
                img.convert(mode = "RGB")
                img.save(self.ImageOutput + os.path.splitext(filename)[0] + '.jpg')
                os.remove(self.ImageOutput + filename)
                
                
            
    def ProduceVideo(self):
        ### ProduceVideo ###     
        path = os.getcwd()
        path = os.path.dirname(path)
        path = os.path.dirname(path)
        inputPath = path + "\\Output\\renamed"
        outputPath = path + "\\Output\\video\\"
        videoname = self.VideoName
        
        video = VideoInfo()   
        video.SetInputDir(inputPath)
        video.SetInputFileFormat( "\\" + "image_%03d.png")
        video.SetStarFrame("0")
        video.SetOutputDir(outputPath)
        video.SetFps("0.25")
        video.SetVideoName(videoname)
        
        ffProcess = Ffmpeg()
        ffProcess.SetFfmpeg(self.ffmpegPath)
        ffProcess.Run('produceVideo', video)
        print("done!")<jupyter_output><empty_output><jupyter_text>using<jupyter_code>if __name__ == '__main__':
    task = TaskImageVideo() 
    task.Rename()
    
    task.ProduceVideo()<jupyter_output>D:\FFmpeg\ffmpeg\bin\ffmpeg.exe
done!
{'fraction_non_alphanumeric': 0.13675582398619499, 'fraction_numerical': 0.005176876617773943, 'mean_word_length': 1.992258064516129, 'pattern_counts': {'":': 0, '<': 8, '<?xml version=': 0, '>': 8, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '2', 'dir': 'jupyter-structured-clean-dedup', 'id': '660039', 'license': 'MIT', 'n_tokens_mistral': 751, 'n_tokens_neox': 733, 'n_words': 121, 'path': 'Blender/Scripts/Demo/.ipynb_checkpoints/ImageVideo-checkpoint.ipynb', 'repo_name': 'unclejimbo/cg', 'size': '2318'}