Live data from Hacker News

Viewing profile — itamarst

itamarst

HN member
Joined
Wed, Feb 24, 2016, 2:14 PM UTC
HN karma
5,611
Public activity
1,521 items

About itamarst

I write about speeding up Python software development, and code, at https://pythonspeed.com

I write about fundamental engineering skills and programmer career advice at https://codewithoutrules.com

I also write a weekly email about all the mistakes I've made both coding and in my career over the past 20 years, so that you can learn and avoid them: https://softwareclown.com

Recent public activity

  1. story
  2. comment
    Comment #48948659

    When this was posted to lobsters someone shared this relevant link: https://curiouscoding.nl/posts/static-search-tree/

  3. comment
    Comment #48948628

    The bucket boundaries are often chosen from a random sample of the data, if the input data is very large. Sorting is O(nlogn), but using binary search per value to assign a bucket …

  4. comment
    Comment #48881121

    Better guesses reduce the number of guesses, so there will be less branch misprediction, but there will still be mispredictions for each remaining branch. So I would guess branchle…

  5. story
  6. story
  7. story
  8. story
  9. story
  10. story
  11. comment
    Comment #44081810

    That's great! Would also be cool (separately from Pydantic use case) to add jiter backend to ijson.

  12. comment
    Comment #44072698

    https://remarkjs.com/

  13. comment
    Comment #44068605

    I talk about this more explicitly in the PyCon talk ( https://pythonspeed.com/pycon2025/slides/ - video soon) though that's not specifically about Pydantic, but basically: 1. Ineff…

  14. comment
    Comment #44066723

    Once you switch to ijson it will not save any memory, no, because ijson essentially uses zero memory for the parsing. You're just left with the in-memory representation.

  15. comment
    Comment #44065918

    msgspec is much more memory efficient out of the box, yes. Also quite fast.

  16. comment
    Comment #44065613

    You can't add extra attributes that weren't part of the original dataclass definition: >>> from dataclasses import dataclass >>> @dataclass ... class C: pass ... >>> C().x = 1 >>> …

  17. comment
    Comment #44065600

    For my PyCon 2025 talk I did this. Video isn't up yet, but slides are here: https://pythonspeed.com/pycon2025/slides/ The linked-from-original-article ijson article was the inspira…

  18. comment
    Comment #44065570

    One key question in these sort of things is how free() works: it is given a pointer, and it has to decide whether this was sampled or not, with _minimum_ effort. Poireau does this,…

  19. story
  20. story
  21. story
  22. story
  23. story
  24. story
  25. comment
    Comment #41719499

    It's somewhat domain specific. Pure Python libraries have easier time supporting new releases than libraries that rely on C APIs, and even slower are those that deal with less stab…