GIF Creator Project

Hello Everyone, I am working on GIF Creator Project and I am looking for source code. I have checked on GitHub and found this list and I have added a sample source code below, I want to know the code is optimized or not from a speed and size wise?

from moviepy.editor import *
from moviepy.editor import *
clip = (VideoFileClip("Gif-Creator/video.webm").subclip((2.25),(6.25))

Here second line in code is redundant beside that your code looks ok, like purpose is full-filed. Beside that python is interpreted language which is why it’s naturally slow. But it wont create a problem for such small projects. So just wanna ask you, beside making basic gifs what is your aim for this project?

Hey, Actually I am working on a project where users can visit a website and download the GIF files in different categories. If you know another source code, then please share it.

The code looks fine to me. It looks optimized.

I’d suggest you to stick to convert from mp4 only, if you are facing issues with conversion.

You can have a glance here -

As per suggested by @akshayan.sinha it is advisable to stick to convert from mp4. Beside that all you need now is to do the UI and Backend coding of website where in the backend you can set the above code and store the gifs in database which can later be fetched by UI.