Pytorch CTCLoss error

When I try to use torch.nn.CTCLoss, with reduction='none', I get the following error.

Now, there is no way I can pass size_average and reduce as parameters to pytorch CTC Loss. I am assuming that these values must be ambiguous right now, hence the error.
Any suggestions?

Do we have anyway to pass these parameters through CTCLoss. My CTCLoss looks something like this -

torch.nn.CTCLoss(reduction=reduction, zero_infinity=zero_infinity, **kwargs)

How are you making your model and declaring it?

Here - asr model