Skip to content

Why get_num_threads() and set_num_threads(1) in engine.py? Is it essential? #3115

Open
@BCMoo

Description

@BCMoo

Hi there,

I'm wondering what's the function of these code? Can i remove them?

Thanks!

https://github.com/pytorch/vision/blob/dab475720f116c42fc80e437b25496dfc94d2a8a/references/detection/engine.py#L72:L74

torch.set_num_threads(n_threads)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions