Giter VIP home page Giter VIP logo

my-python-practices's Introduction

my-python-practices

simplemultithreadsCrawler.py:

一个简单的多线程生产者消费者爬虫,实际使用的时候可以重写parser的parse_links方法,来写自己的解析规则,
然后将解析后将继续要爬的地址放入url队列,生产者会自动爬

sync-flood.py:

利用scapy构造包sync包,具有统计pps的功能,但是性能较差,而且scapy会响应服务器ack包

watch_sync.py:

监听本地目录,当目录下的文件被更改、删除、新增时,远端目录下的文件会相应被更改、删除、新增
使用的pyinotify模块监听目录,paramkio上传文件到远端
当变成守护进程时,将标准输出重定向到文件不起作用,不知道定向到哪去了,求大神帮忙看看

my_mutex.py:

使用redis实现一个锁,可用作多进程或者分布式锁

find_tail_lines.py:

实现读取打印文件末尾倒数N行开始M行内容

trie.js:

js实现的一个前缀树,性能强悍,不知道这归功于前缀树还是js哈哈。可以用来统计词频、单词查询、前缀匹配。

my-python-practices's People

Contributors

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