News for hackers. Stuff that matters.

bluehorseray

pdftotext in python works pretty well:

  import pdftotext
  import sys
  
  with open("test.pdf", "rb") as f:
    pdf = pdftotext.PDF(f,physical=True)

  for page in pdf:
    print(page)
Here's a stackoverflow link with a similar question: https://stackoverflow.com/questions/34732718/why-isnt-there-...

I actually don't know if there are fonts to cover every single unicode character, but I could be wrong.

I'll suggest a ridiculous hack, but could end up being a cool little project to try to get working.

I recently built a web page to display random unicode characters, and I saw that if a character isn't supported by a font it would show up as a square / rectangle.

I ended up checking to see if a character was supported by drawing the characters to HTML canvas, and then iterating through the pixels to check if it matched that square shape (there's probably a better way to do it).

You could do something similar, and then for all "unsupported" characters found, make a request to this URL with the second to last parameter being the unicode char: https://www.fileformat.info/info/unicode/char/0041/fontsuppo...

Then scrape that page for the supporting font names.

Maybe I'm wrong, but I find the discussion around "reminding" yourself to have good posture off-base. It's like saying that if you want larger biceps, you should walk around with your biceps flexed all day. I feel like the important part is strengthening your postural muscles, and then just living normally
If you spend less than or equal to 2/3 of your current income right now you should be able to quit with 0 years living expenses covered. If you spend all of your current income right now, and your 5 years living expenses assume 0 income than you essentially have 15 years of runway. Seems fine to me if your math is right
I honestly think there's a huge market for a consumer grade "pet" robot. Would love to have one of these running around, then I can just turn it off when I leave
Should happen every ~115 days
Re:OpenAI CEO Sam Altman on Lex Fridman Podcast on Saturday March 25, 2023 @04:01PM (#35306665)
14:17: "I suspect too much of the processing power is going into using the model as a database instead of using the model as a reasoning engine"

https://youtu.be/L_Guz73e6fw?t=857

- "ftxbro"
I think it's Elon's response to his "all active design projects" claim.

I'd be surprised if he led "the prioritization of [all] design projects across the company to make sure we were able to deliver with a small team" and Elon doesn't know who he is.

Re:Meta Must Succeed on Sunday February 12, 2023 @12:04AM (#34759994)
Are you writing meta fanfiction?
Re:Ask HN: What's a website you wish more people knew about? on Thursday January 26, 2023 @06:09PM (#34540179)
https://news.ycombinator.com/ for me as well. Interested to hear other people's opinions.
Re:Tell HN: You were never right about anything on Friday January 06, 2023 @07:34PM (#34283508)
I'll be honest this is pretty incoherent.

What hasn't improved over the past 15 years? All HN cares about is making new laws? Please re-write

Re:Sergey Brin: “Irate Call from Steve Jobs” on Monday January 02, 2023 @11:02PM (#34227501)
It would be pretty cool to have Steve Jobs and Sergey Brin fighting over you as an employee, wonder who it was.
Re:Trump’s Major Announcement Is $99 Digital Trading Cards on Thursday December 15, 2022 @12:23PM (#34002753)
Truly hilarious. From the four seasons incident to NFTs, he just constantly straddles this line between incredibly sleazy and incredibly funny. I can never tell if it's a bit

https://collecttrumpcards.com/images/DT-White-Hat.webp

Try to find a 3rd party phone repair shop. There's a decent chance they can get your old phone charging pretty quickly and cheaply if it's just your charging port being dirty / faulty.
Re:Is This End of China? on Sunday December 04, 2022 @11:05PM (#33861322)
If anything I think China no longer manufacturing cheap foreign goods will strengthen them in the longterm
Hmm this sees pretty prohibitive for a lot of people. Hope it gets delayed again
Re:Bring Back Vine? on Sunday October 30, 2022 @11:40PM (#33401807)
I could be wrong, but I think Twitter was just about to introduce videos to the platform and saw Vine as a competitor. So they shut it down. I've always thought that was a pretty big mistake.
Re:Bring Back Vine? on Sunday October 30, 2022 @11:33PM (#33401785)
I totally forgot Twitter bought Vine. This is interesting, I've always thought the US never banned TikTok partially because it's so popular. If Musk does bring Vine back and successfully competes with Tiktok, maybe the gov will help him out and ban it.
Re:Ask HN: How many are switching to Mastodon? on Thursday October 27, 2022 @11:03PM (#33367125)
It's been ~6 hours since Musk closed the deal. Maybe he shadow banned your account in the afternoon
Re:Ask HN: Two women I referred to a company were bullied out on Tuesday October 25, 2022 @08:29PM (#33338136)
Leak it
Hehe "purgatorial"
you renegade!
Re:Bay Area Bed Frame Grants on Monday October 03, 2022 @10:58PM (#33076283)
How did you make $80M?
Re:Nord Stream: Tie-ins and hyperbaric welding on Wednesday September 28, 2022 @01:44AM (#33004619)
That's actually why I looked this up in the first place. I think it's just air from what I could gather. The three sections of the pipe are laid on the seafloor like this (with the open end staying out of the water): https://www.wermac.org/nordstream/html_img66.html.

And then those three sections are welded together using an "air-tight habitat" surrounding them.

From what I've heard salt water getting into the pipe could make it really difficult to repair, and it might have to be scrapped altogether.

Older »