上一页 1 ··· 5 6 7 8 9 10 11 12 13 ··· 16 下一页
该文被密码保护。 阅读全文
posted @ 2020-10-13 10:11 皮卡皮卡妞 阅读(228) 评论(0) 推荐(0) 编辑
摘要: def tensor2im(image_tensor, imtype=np.uint8, normalize=True): image_numpy = image_tensor.cpu().float().detach().numpy() if normalize: image_numpy = (i 阅读全文
posted @ 2020-10-13 10:02 皮卡皮卡妞 阅读(539) 评论(0) 推荐(0) 编辑
摘要: import os import numpy as np import cv2 old_ng='./train_B/' new_wg_dir='./clear/train_A/' new_ng_dir='./clear/train_B/' if not os.path.exists(new_wg_d 阅读全文
posted @ 2020-10-10 17:25 皮卡皮卡妞 阅读(361) 评论(0) 推荐(0) 编辑
摘要: pytorch1.1.0+python 参考博客https://blog.csdn.net/Cxiazaiyu/article/details/91129657 降低版本到: pytorch1.0.1错误消失,但是出现新的错误: 阅读全文
posted @ 2020-10-10 11:20 皮卡皮卡妞 阅读(787) 评论(0) 推荐(0) 编辑
摘要: pytorch1.3.0+python 问题:pytorch版本过高 解决: https://download.pytorch.org/whl/cu100/torch_stable.html 下载低版本的pytorch,这里下载的是1.1.0 问题解决。 阅读全文
posted @ 2020-10-10 09:21 皮卡皮卡妞 阅读(790) 评论(0) 推荐(0) 编辑
摘要: 1、nvcc -V 查看cuda版本 2、查看pytorch版本 3、安装pytorch pip install torch==1.0.1 -f https://download.pytorch.org/whl/torch_stable.html 4、安装torchvision pip instal 阅读全文
posted @ 2020-10-09 17:22 皮卡皮卡妞 阅读(170) 评论(0) 推荐(0) 编辑
摘要: 报错: 修改: model.module.optimizer_G.zero_grad() loss_G.backward() model.module.optimizer_G.step() 为: model.module.optimizer_G.zero_grad() loss_G.backward 阅读全文
posted @ 2020-09-25 15:47 皮卡皮卡妞 阅读(2946) 评论(0) 推荐(0) 编辑
摘要: 一、vs code 的常用快捷键 1、注释: a) 单行注释:[ctrl+k,ctrl+c] 或 ctrl+/ b) 取消单行注释:[ctrl+k,ctrl+u] (按下ctrl不放,再按k + u) c) 多行注释:[alt+shift+A] d) 多行注释:/** 2、移动行:alt+up/do 阅读全文
posted @ 2020-09-25 15:16 皮卡皮卡妞 阅读(492) 评论(1) 推荐(1) 编辑
摘要: model_dict = torch.load(save_path) fp = open('model_parameter.bin', 'wb') weight_count = 0 num=1 for k, v in model_dict.items(): print(k,num) num=num+ 阅读全文
posted @ 2020-09-25 15:13 皮卡皮卡妞 阅读(4994) 评论(0) 推荐(0) 编辑
摘要: pytorch+python 错误: 纠正: self.trace, _ = torch.jit.get_trace_graph(self.model, args=(self.x,)) 为: self.trace, _ = torch.jit._get_trace_graph(self.model, 阅读全文
posted @ 2020-09-25 15:09 皮卡皮卡妞 阅读(3126) 评论(0) 推荐(0) 编辑
上一页 1 ··· 5 6 7 8 9 10 11 12 13 ··· 16 下一页