I am trying to follow the pytorch code for the ssd implementation (Github link 15).
Inside ssd.py at this 8 line there is a call to contiguous() after permute().
            loc.append(l(x).permute(0, 2, 3, 1).contiguous())

Following the discussion here, I understand the use of contiguous() but I can’t understand why it was called after permute()?
Is it necessary or good practice to call it after every call to permute()? Is it to avoid any “surprise” errors later in the model while accessing the tensor?