Code Monkey home page Code Monkey logo

2018-bd-xjd's Introduction

2018-BD-XJD


2018百度西交大大数据竞赛-商家招牌的分类与检测-初赛



【CSDN博客】https://blog.csdn.net/u013063099/article/details/80533694

【运行环境】Windows 10,PyTorch 0.4.0

【简介】单模型ResNet152最高线上评分0.99
第一步 数据预处理(utils/image_preprocessing.py)。根据CSDN博客中的处理阶段(V1.1-V1.4)将处理之后的数据存在dataset/data中(例如第四阶段V1.4我存到文件夹train_improve_v4中)。根据需要可以对扩增的数据进行调整图片大小、灰度化等等。然后将原来的train.txt其中的原图片名可以加上不同的前缀代表预处理之后的新图片名,label不用改。用Excel等工具进行扩充(各种复制粘贴……),形成新的label文件(例如train_improve_v4.txt)。
第二步 训练。使用新扩增的训练集以及label文件进行训练。训练过程中的模型权重以pth文件形式保存在output文件夹中。后来可能发现带着验证集的效果并不好,干脆直接去掉验证集,把所有的训练集图片全部训练。全部训练使用train_only.py,带验证集的训练使用train_val.py。
第三步 预测(predict.py)。使用保存的pth模型文件(保存时文件名会带有loss值标识),选择一个最低的损失值的模型(通常选损失为0.00001的),最后生成的csv保存在output文件夹下。提交等待线上评分即可。

用了个比较脑残的投票法(utils/voting.py),投了个0.991。。。=.=|||

目前线上最高评分0.991。

2018-bd-xjd's People

Contributors

wfdubowen avatar

Watchers

James Cloos 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.