Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def __init__(self, pnet_type='vgg', pnet_tune=False, use_dropout=False, use_gpu=True):
super(PNetLin, self).__init__()
self.use_gpu = use_gpu
self.pnet_type = pnet_type
self.pnet_tune = pnet_tune
if(self.pnet_type in ['vgg','vgg16']):
net_type = pn.vgg16
self.chns = [64,128,256,512,512]
elif(self.pnet_type=='alex'):
net_type = pn.alexnet
self.chns = [64,192,384,256,256]
elif(self.pnet_type=='squeeze'):
net_type = pn.squeezenet
self.chns = [64,128,256,384,384,512,512]
if(self.pnet_tune):