Giter Club home page Giter Club logo

Comments (4)

kalessin avatar kalessin commented on June 23, 2024

No, it doesn't. You can check that with the CPU usage in your machine while you crawl.

Crawling speed depends on many factors, not only your machine capabilities. It depends also on the settings you are using for the job, and on the target server.

from portia.

mezuqu avatar mezuqu commented on June 23, 2024

i would rephrase my question, what difference would i get if i do the same crawling with pure scrapy and scrapy using portia

from portia.

kalessin avatar kalessin commented on June 23, 2024

There can be of course a small CPU usage cost, but that is not the usual case (unless the target site has very very big pages, and even on that case probably the cost is not important). As I said, you can check CPU usage by yourself. Also, we crawl at much higher speeds than you get, using scrapely/slybot (portia).

Again, crawling speed depends on many other factors, which does not came from a difference between pure scrapy and portia. I would start by checking settings/middleware differences between your runs with scrapy and with portia.

from portia.

ruairif avatar ruairif commented on June 23, 2024

There are some benchmarks in slybot that compare parsel extraction speed to scrapely extraction speed:

test_extraction_speed.TestExtractionSpeed.test_slybot_parse_and_extract: 20.4085s
test_extraction_speed.TestExtractionSpeed.test_parsel_parse_and_extract: 16.3027s
test_extraction_speed.TestExtractionSpeed.test_parsel_extract: 12.9132s
test_extraction_speed.TestExtractionSpeed.test_slybot_extract: 10.6147s

These tests are extracting from 300 pages extracting 10-15 items from each page. As you can see the part that slows down scrapely compared to parsel is the parsing which is written in python compared to lxml which is written in C. There was an attempt made to convert the scrapely parser from python to cython but unfortunately this didn't work on all pages so it was disabled. With the cython parser scrapely was faster than parsel so we need to look at fixing the bugs in cython parser and re-enabling it.

from portia.

Related Issues (20)

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.