当前位置:网站首页>TransGAN code reproduction - Jiutian Bisheng Platform
TransGAN code reproduction - Jiutian Bisheng Platform
2022-07-30 21:32:00 【Medium Coke with ice】
TransGAN是UT-Austin、加州大学、 IBMChinese Ph.D. students at the Institute constructed a using only pure transformer 架构、No convolution at all GAN,并将其命名为 TransGAN.
论文地址:https://arxiv.org/abs/2102.07074
论文精读:论文精读 TransGAN
代码地址:https://github.com/VITA-Group/TransGAN
This blog post is reproduced using China Mobile's Jiutian Bisheng platformTransGAN的博文.
一、An introduction to the operation of Nine Days Bisheng
First, let's introduce the deep learning service platform:“九天·毕昇”是中国移动A cloud service platform developed,能够提供高效(Maximum video memory32GB的V100)便捷(The main advantage is still免费O(∩_∩)O)的算力.
点击链接注册即可免费赢取 1000 个算力豆(50 小时 V100 使用时长:https://jtedu.cmri.cn/web#/register?token=NTIxNWNkOWEtNjIxZi00ZTIyLThlZTItNDhiYWQ3ODRiMDhm
1.1、进入控制台
进入首页后,点击进入控制台:

After entering, you can see the storage space,算力豆(The unit of calculation for the nine-day Bisheng calculation)and their own established examples.
1.2、Create your own instance

点击左侧导航栏,进入模型训练,点击新建实例
Name your own instance name,然后选择数据集(The platform provides some datasets,The selected platform dataset is automatically loaded in data/public文件夹中,But the platform is only
部分数据集,Datasets that do not have to be uploaded by themselves in data management or when running the instance)Select a resource plan.
1.3、进入实例
进入实例后,我们可以看到,和colab比较类似,On the left is the file resources section,Editing is possible on the right,
We click on the blue plus sign in the upper left corner,新建一个notebook或者consoleor the bottom oneterminal(看个人喜好),如果点击的是pytorch1.x,Then the platform automatically loads the most basic onespytorch环境.
二、复现TransGAN
2.1、下载git代码
首先进入终端terminal,克隆代码:
git clone https://github.com/VITA-Group/TransGAN

After a successful clone,项目代码如下:
2.2、配置环境
进入TransGAN:cd TransGAN,
然后根据requirement.txt下载安装环境:
pip install -r requirements.txt
可能会出现的问题:
ERROR: conda 4.11.0 requires ruamel_yaml_conda>=0.11.14, which is not installed.
ERROR: tensorflow 2.4.0 has requirement absl-py~=0.10, but you’ll have absl-py 1.0.0 which is incompatible.
ERROR: tensorflow 2.4.0 has requirement flatbuffers~=1.12.0, but you’ll have flatbuffers 2.0 which is incompatible.
ERROR: tensorflow 2.4.0 has requirement gast==0.3.3, but you’ll have gast 0.5.3 which is incompatible.
ERROR: tensorflow 2.4.0 has requirement grpcio~=1.32.0, but you’ll have grpcio 1.45.0 which is incompatible.
ERROR: tensorflow 2.4.0 has requirement h5py~=2.10.0, but you’ll have h5py 3.6.0 which is incompatible.
ERROR: tensorflow 2.4.0 has requirement numpy~=1.19.2, but you’ll have numpy 1.21.5 which is incompatible.
ERROR: tensorflow 2.4.0 has requirement six~=1.15.0, but you’ll have six 1.16.0 which is incompatible.
ERROR: tensorflow 2.4.0 has requirement typing-extensions~=3.7.4, but you’ll have typing-extensions 4.1.1 which is incompatible.
解决方案:这个的意思是tensorflow 2.4The version does not match the version of some other environment.
需要重新安装TensorFlow:
pip install tensorflow
2.3、开始训练
在TransGAN目录下,输入:
python exps/cifar_train.py
开始训练:
训练的时间比较长,可能需要2天或者更久,We can also download already trained onescheckpoint进行测试(请看2.4).
2.4、开始测试
如果2.3No training or finish,下载 cifar checkpointand put it in a folder:
Finally enter the test command,开始测试:
python exp/cifar_test.py
可能遇见的问题:
ModuleNotFoundError: No module named ‘tensorflow._api’
解决方案1:
Refer to the online speculation to install on the command linetensorflow-gpu,在命令行输入:
pip install --upgrade --ignore-installed tensorflow-gpu
解决方案2:
TensorFlow未安装成功,重新pip安装
福利
点赞、评论+收藏三连,You can private message me to receive exclusive hashrate beans!(活动截止2022年6月29日)
边栏推荐
- [Machine Learning] The Beauty of Mathematics Behind Gradient Descent
- socket:内核初始化及创建流(文件)详细过程
- Quick Master QML Chapter 6 Animation
- 深入浅出富文本编辑器
- (7/29) Basic board minimum spanning tree prim+kruskal
- 微信公众号授权登录后报redirect_uri参数错误的问题
- ClickHouse 数据插入、更新与删除操作 SQL
- ArrayList扩容机制分析
- 文字的选择与排版
- Niu Ke Xiaobaiyue Race 53 A-E
猜你喜欢

Markdown的使用

Typescript 严格模式有多严格?

【网络安全专栏目录】--企鹅专栏导航

Deep Kalman Filter Network for Video Compression Artifact Removal

DPW-SDNet: Dual Pixel-Wavelet Domain Deep CNNsfor Soft Decoding of JPEG-Compressed Images

Outsourcing worked for three years, it was abolished...

Apache DolphinScheduler新一代分布式工作流任务调度平台实战-上

LeetCode·Daily Question·952. Calculate Maximum Component Size by Common Factor·Union Check

你需要知道的ES6—ES13开发技巧

活动推荐 | 2022年深圳最值得参加的边缘计算活动
随机推荐
socket:内核初始化及创建流(文件)详细过程
LeetCode · 23. Merge K ascending linked lists · recursion · iteration
mysql deadlock
How strict Typescript strict mode?
类似 MS Project 的项目管理工具有哪些
WinDbg实践--入门篇
系统结构考点之PM2I单级网络
为什么那么多自学软件测试的人,后来都放弃了...
牛客小白月赛53 A-E
C语言犄角旮旯的知识之结构体
JDBC (detailed explanation)
共用体、共用体与结构体的区别、枚举之C语言犄角旮旯的知识
手动从0搭建ABP框架-ABP官方完整解决方案和手动搭建简化解决方案实践
用于命名实体识别的模块化交互网络
(7/29) Basic board minimum spanning tree prim+kruskal
MySQL 游标
Oracle ADG状态查看与相关视图
ClickHouse 创建数据库建表视图字典 SQL
MySQL 灵魂 16 问,你能撑到第几问?
mysql死锁