Cache examples?

#1
by victor HF staff - opened

Nice Space!
It would be cool to cache the examples (to quickly try out the model)
https://gradio.app/more_on_examples_and_flagging/#caching-examples

Hi Victor,

I have a problem using that feature. I opened this thread: https://discuss.huggingface.co/t/problem-showing-mp4-examples-on-spaces/22801

Now I simulate the cache by uploading the results, you can try the soccer video with the YOLOv7 model and activate the checkbox "Use cache example result".

Do you know another solution for this error?

Thanks for the comment.

I fixed this problem by setting default arguments to the function called by the interface.

This function fails with cache_examples=True because when the app starts it doesn't receive any arguments to run over the example videos.

Greetings.

Hi, it seems to work! thank you ๐Ÿค—๐Ÿค—

diegofernandezc changed discussion status to closed

Sign up or log in to comment