Imported from https://github.com/bayesgroup/pytorch-ensembles