3 ms·
Hi joosters, thanks for the question. It is always a good practice to ask if we are solving the right problem. The decision to prewarm is ultimately a product
by wsuen 6y ago
Hi joosters, thanks for the question. It is always a good practice to ask if we are solving the right problem.
The decision to prewarm is ultimately a product decision to give users a better experience across the many surfaces where they encounter file previews. There are limitations to how fast previews can be generated on the fly, even under optimal conditions (unlimited top-of-the-line hardware, max of 1 request at a time). For instance, optimal on-the-fly preview generation for more expensive files (say, a video that is an hour long or a gigapixel image) can add 10s of seconds to tti -- not good from a user perspective!
Given this constraint, we wanted to optimize where we spend on the preview generation infrastructure without negatively impacting the user experience. We chose to do this with a combination of heuristics and the ML solution described in the article.
- catmanjan 6y agoCouldn't you just load the first frame of the video, and aren't most image formats optimized for fast thumbnailing? I take your point that there are times when it will be slower, but are you saying that you assumed ML would be faster than on the fly, or did you actually check?
- ddorian43 6y ago> Couldn't you just load the first frame of the video No, often it's black. You have to do scene-detection if you want meaningful previews/thumbnails, can't always go random about it. And the original files are stored in HDD and not SSD/RAM. Source: I don't work there.