Giter VIP home page Giter VIP logo

tianchi_lvcai's Introduction

天池图像比赛Baseline分享

运行代码前,需要将图片放在data目录下,目录树如下:

|--data
	|--guangdong_round1_train1_20180903
	|--guangdong_round1_train2_20180916
	|--guangdong_round1_test_a_20180916
|--gen_label_csv.py
|--model_v4.py
|--main_inception_v4.py

代码运行方式:

python gen_label_csv.py
python main_inception_v4.py

程序说明:

框架:Pytorch 0.4

代码经测试,线上分数为0.921,线上19名(截至2018.9.20)。

如果有版本迭代,只需修改主程序名,则代码会自动生成新目录用于保存模型与结果文件。

使用的模型为ImageNet预训练的inception v4,整体思路:数据增强之后直接将网络全部层一起训练,做简单分类。

本代码为baseline,未经任何调参,训练参数和数据增强方式等可以自行随意修改。

输入尺寸为384×384,如果出现out of memory(显存不足),可减小batch size再重新跑。

注:只用到了guangdong_round1_train2_20180916数据,没有使用guangdong_round1_train1_20180903,可自行添加。

许多同学反应Windows下训练时train_loader报错的问题,将workers设为0即可解决。

tianchi_lvcai's People

Contributors

herbert-chen avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.