Skip to content

Conversation

@asterocean
Copy link

Partially solve OUT OF MEMORY problem by preload modules on demand versus preload all modules at the same time. After these modifies, run smoothly on my 8GB graphic card.

Partially solve OUT OF MEMORY problem by preload modules on demand versus preload all modules at the same time.
After these modifies, run smoothly on my 8GB graphic card.
models.clear()
if preload_type == "text":
_ = load_model(
model_type="text", use_gpu=text_use_gpu, use_small=text_use_small, force_reload=force_reload
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
model_type="text", use_gpu=text_use_gpu, use_small=text_use_small, force_reload=force_reload
model_type=preload_type, use_gpu=text_use_gpu, use_small=text_use_small, force_reload=force_reload

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

Successfully merging this pull request may close these issues.

2 participants