team-10/venv/Lib/site-packages/torch/utils/data/backward_compatibility.py

12 lines
309 B
Python
Raw Normal View History

2025-08-02 02:00:33 +02:00
# mypy: allow-untyped-defs
from typing_extensions import deprecated as _deprecated
@_deprecated(
"Usage of `backward_compatibility.worker_init_fn` is deprecated "
"as `DataLoader` automatically applies sharding in every worker",
category=FutureWarning,
)
def worker_init_fn(worker_id):
pass