Giter Club home page Giter Club logo

pornhubspider's Introduction

Pornhub爬虫

一个可以获取Pornhub视频和Cover的爬虫程序

发布时间:2020.05.23

最近更新:2020.05.24

环境&模块:

🍰开发环境:Python3 Win10 PyCharm
🍭测试环境:Win10 Ubuntu Centos Debian
🍥模块:re,requests,lxml,time,os

实现功能:

  • 所有下载视频均为最高清晰度
    4k在想:peach:
  • 解析单个视频真实链接
    • 输出真实链接
    • 选择是否下载
  • 解析某个页面所有视频真实链接 可批量下载
  • 保存视频到相应标题目录下mp4文件以当日时间命名
  • 保存封面到相应标题目录下jpg文件以Cover命名

⚠️
PS:由于官方限制,解析到的视频链接只能通过解析该链接的IP进行下载!
真实链接放到其他IP进行访问会出现403,无权访问。

使用:

Python3环境

Centos:

yum install python3 python3-pip -y

Debian:

apt-get install python3 python3-pip -y

Ubuntu:

sudo apt-get install python3 python3-pip -y

模块安装&项目拉取

1.安装所需模块

pip3 install requests lxml

2.拉取项目

git clone https://github.com/moeik/PornhubSpider.git && cd PornhubSpider

3.运行

python3 app.py

快捷方式

chmod +x app.py
ln -sf /绝对路径/app.py /usr/bin/ph

随后在任意目录运行ph即可

进程守护

安装Screen

Centos:

yum install screen -y

Debian:

apt-get install screen -y

Ubuntu:

sudo apt-get install screen -y

守护进程

新建窗口

screen -S <name>

返回窗口

screen -r <name>

在新窗口中运行python3 app.py即可
PS:<name>为自定义名称,如:screen -S PH


目录结构:

|——Pornhub
|   |——{title}
|      |——{time}.mp4
|      |——Cover.jpg

声明:

  • 本项目只是个人爬虫初上手项目,代码较乱,大佬勿喷。
  • 练手项目难避免有很多Bug,也欢迎提交Bug,在能力范围内进行改进。
  • 欢迎大家Star。

pornhubspider's People

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.