Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Model takes several minutes to download occasionally #154

Open
bertagknowles opened this issue Aug 24, 2024 · 8 comments
Open

Model takes several minutes to download occasionally #154

bertagknowles opened this issue Aug 24, 2024 · 8 comments

Comments

@bertagknowles
Copy link

bertagknowles commented Aug 24, 2024

When running my json workflow through api in my application, most of the times it downloads the required models and runs within a minute. However at times it takes several minutes and when I checked the logs, it showed that it took 4 minutes to download a model. Why does this happen occasionally and is there a way to ensure that if the models take more than a minute to download, the prediction is cancelled or errored out? This extra time adds to my billing :(
scrnsht01

@aichromator
Copy link

Yes, same issue. especially when multiple models are options available for a custom node, it loads all. How do we solve it?

@fofr
Copy link
Owner

fofr commented Aug 28, 2024

My best guess here is that this is a cache miss on Replicate's side, meaning the weights download slower. Any subsequent requests shouldn't have that problem.

@bertagknowles
Copy link
Author

Hmm, then I think I'll create an automatic cancel after a set time in the application side.

@bertagknowles
Copy link
Author

bertagknowles commented Aug 29, 2024

The problem is that if I use a timer to cancel requests after one minute, then the requests that are waiting in queue will also be cancelled since sometimes in public models the queue can also take more time. Will it be possible for you to add in the backend that if the download time exceeds one minute or if the cache is missed then the request should time out/fail? I think most models even ones around 23gb like flux etc should not take more than a minute to download from a parallel cache. This will save unnecessary billing costs for everyone.

@bertagknowles bertagknowles reopened this Aug 29, 2024
@bertagknowles
Copy link
Author

bertagknowles commented Sep 9, 2024

Got this error and was billed unnecessarily for 30 minutes :( ....something is broken....this is not reliable for api

error

@fofr
Copy link
Owner

fofr commented Sep 9, 2024

@bertagknowles FYI, you are not billed for failed predictions. You won't be billed for this.

@bertagknowles
Copy link
Author

Oh, that's a big relief...thanks for letting me know.

@bertagknowles
Copy link
Author

bertagknowles commented Sep 9, 2024

However, there is something wrong with the model lately and the output file is not being shown (blank).
error2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants