PyTorch is BSD licensed.
If you write New Code in your own repository, you can license it under whatever license you want.
If you are distributing PyTorch code as-is, you have to preserve PyTorch code license in the distribution.