Can't import ConstantLR scheduler

When I trie to use ConstantLR or some other schedulers I get the error: AttributeError: module ‘torch.optim.lr_scheduler’ has no attribute ‘ConstantLR’. I already tried to update pytorch version and nothing changed, I’m currently using version 1.6. Has anyone faced this issue? Any help is appreciated!

it wasn’t present in 1.6, and that version is about a year old

1 Like

My mistake! I didn’t notice an error when I tried to update, sorry. Thanks!