Thank you very much sir.
I changed my resume section as following :
    ...
    #loading the model in gpu
    model = mysimplenet(1000)
    model = torch.nn.DataParallel(model).cuda() 

    if args.resume:
        if os.path.isfile(args.resume):
            print_log("=> loading checkpoint '{}'".format(args.resume), log)
            checkpoint = torch.load(args.resume)
            args.start_epoch = checkpoint['epoch']
            best_prec1 = checkpoint['best_prec1']
            if 'best_prec5' in checkpoint:
                best_prec5 = checkpoint['best_prec5']
            else:
                best_prec5 = 0.00

            #model.load_state_dict(checkpoint['state_dict'])
            
            mapping = {}
            idxold = 0
            for i,l in enumerate(model): # model contains dropout
                if not isinstance(l, torch.nn.Dropout):
                    mapping[idxold] = i
                    idxold += 1
            
            sd1 = checkpoint['state_dict'] # load from existing checkpoint state_dict which does not have dropout
            sd1.keys()
            sd2 = {}
            for k in sd1:
                ksplit = k.split('.')
                ksplit[0] = str(mapping[int(ksplit[0])])
                knew = '.'.join(ksplit)
                sd2[knew] = sd1[k]

            model.load_state_dict(sd2)

            #loading scheduler state
            if no_scheduler_stat:
                scheduler.load_state_dict(tmp)   
            else:      
                scheduler.load_state_dict(checkpoint['scheduler'])

            optimizer.load_state_dict(checkpoint['optimizer'])
            model.eval()
            print_log("=> loaded checkpoint '{}' (epoch {})".format(args.resume, checkpoint['epoch']), log)
        else:
            print_log("=> no checkpoint found at '{}'".format(args.resume), log)

However, I’m facing with TypeError: 'DataParallel' object is not iterable
What am I doing wrong here? What should I do?