Coder Social home page Coder Social logo

zhainanfuli's Introduction

更新

2020-2-18:

发现用代理下载图片的过程中,会出现图片不完整

同时这种情况还很多

随即更新了一版

通过二进制图片结尾 '\xd9' 来判断
下载过程中,判断该图片是否为完整图片
同时对于已经下载的图片仍旧判断是否为完整图片 不完整则重新下载
牺牲了一定的性能,但是保证完整性

项目简介

首先感谢各位通过传送门来到这里,请star 图一

这里有个故事,受朋友的委托去采集一位叫ycc的麻豆的图 看来看去觉得漂亮,就在twitter上搜罗了一番 随后发现此人曾经在秀人网叫gxx 随后笔者觉得整容前其实看着更有味道点 随后去搜gxx,然后就找到这个网站

没有被墙不容易啊,请珍惜

不过这个网站有个蛋疼的地方就是 浏览一个图集的时候,需要不断的翻页,用户体验很差 所以笔者当下决定,写个爬虫撸一遍

截止笔者发稿,一共采集到15w张图片的url,正持续下载中 为了影响人家到最小,笔者很轻柔的爬 所以也希望各位请轻柔对待

示例

致"宅福利"网站

首先跟"宅福利"这个网站的所有人说一声抱歉把您收集分享的图片给割了一波韭菜

前言

一次性系列,爬虫按照怎么快怎么写

所以说格式啊

代码风格啊

功能里的持久化啊

通通都没顾及

注意: 图片的集合已经采集好了,各位只需要clone 后 直接下载就行

环境

python3
所需库:
requests
lxml

目录:

目录

.
├── AISSaisi                # 爱丝图集
├── luyilu                  # 撸一撸图集
├── meiyanshe               # 魅妍社图集
├── meiyuanguan             # 美媛馆图集
├── tuinvlang               # 推女郎图集
├── youguo                  # 尤果图集
├── README.md               # readme
├── seeds_list.txt          # 所有图片url
├── image_list.txt          # 所有图集url
├── download_imags.py       # 图片下载
└── download_seeds.py       # 种子下载 

启动方式

下载种子:
python3 download_seeds.py

自动遍历该网站所有分类,然后遍历各个分类里具体的图集,并保存下url

下载图片:
默认是 10个进程下载,需要的话,自己进代码里修改

python3 download_images.py

说明, 图片链接我已经采集好了,不用再下载种子了,直接下载图片就行了

zhainanfuli's People

Contributors

beforeuwait 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.