HNHacker News
TopNewBestAskShowJobs

rovyko

106 karma · joined December 29, 2018

submissionscomments
rovyko··on Ask HN: How to connect with experts outside of the tech domain?
The cold call approach is something I've been hearing a lot. It's scary to just start talking to people when you have no experience, but I think that's just life. It was the same with negotiating salary, learning new thing and meeting new people. You just need an objective goal, courage and a way to learn from failures.

Thanks for your input!

rovyko··on Show HN: Easy placeholders for SQL queries when using psycopg2 in Python
In psycopg2, variables can be inserted into queries using %s placeholders and supplying arguments to cursor.execute, but this does not allow for identifier arguments such as table or columns names. The alternative is to use psycopg2.sql.SQL.format, but this requires arguments to be converted into Composable objects such as Literal or Identifier.

With TemplateQuery, instead of wrapping arguments with psycopg2.sql classes (e.g. Literal, Identifier) the expected class can be written inside the query:

  >>> TemplateQuery('SELECT * FROM {table@Q} WHERE {@I} {@S} {value@L}').format(
  ...    'column_name', '>=', table='public.my_table', value=100
  ... ).as_string(conn)
  
  'SELECT * FROM "public"."my_table" WHERE "column_name" >= 100'
The character after the at sign @ in the placeholder key is the transformation that is applied to the argument before inserting it into the placeholder (S for raw SQL, I for Identifiers and L for literals, among others).

I wrote this small library while working on my master's thesis to help run similar analysis queries on different tables and schema configurations, without the mental overhead of wrapping arguments in the proper classes. I'm not sure if it will be useful to anyone, but I thought it was worth releasing. Would appreciate any feedback at all!

rovyko··on Metagenomic Analysis of a Blood Stain from French Revolutionary Jean-Paul Marat
>If you are a computer programmer considering a career change you should really take a day off to look into the new genetic technologies on offer.

What resources would you recommend, and do you have any advice for someone who is just starting their career?

rovyko··on Escher-Like Spiral Tilings
This would make a great visualization for a bassy music video. Link variables defining the polygon shape with amplitudes for bass frequency ranges and the color to the vocal tone.
rovyko··on If the Tuition Doesn’t Get You, the Cost of Student Housing Will
I wouldn't mind a shared bathroom or kitchen, but I don't understand the massive living rooms. My guess is it makes the unit more marketable to higher income students that in a lower volume can pay more in total for a given plot of land.
rovyko··on If the Tuition Doesn’t Get You, the Cost of Student Housing Will
You got it. I was lucky to start when it was affordable. The residence fees this year are completely insane. $1000/mo for a single dorm room and even more for a room in a 3-4 bedroom apt. Off-campus housing isn't much better.
rovyko··on If the Tuition Doesn’t Get You, the Cost of Student Housing Will
I lived in university-run student residence and in student-oriented rentals. The amount of wasted space was unbelievable considering everybody spent the vast majority of their time on campus. We didn't need an 86sqft living room, it just filled up with garbage. I couldn't find an apartment with just bedrooms, a tiny kitchen and a bathroom.

What I really wanted was one of these tiny apartments [0]. Build a whole apartment of these near campus, students only sleep at home anyway, and sometimes not even that. My univeristy is building a new residence and it has the same 3-5 bedrooms to a giant apartment with a living room.

I wonder what's the main barrier to building a lot of tiny single student apartments. Is it the municipal regulations, are they not economical or did research show that students actually want living rooms?

EDIT: Just look at the size of these living rooms. I've been in so many of these apartments and they're almost always full of boxes and trash.

- http://www.rez-one.ca/wp-content/uploads/2016/11/MG_6020.jpg

- http://www.rez-one.ca/wp-content/uploads/2016/11/MG_5991.jpg

- https://uwaterloo.ca/housing/sites/ca.housing/files/uploads/...

- https://uwaterloo.ca/housing/sites/ca.housing/files/styles/i...

- https://uwaterloo.ca/housing/sites/ca.housing/files/styles/i...

- https://static.wixstatic.com/media/29eef9_c0378e178fda4f0b84...

0. https://www.youtube.com/watch?v=TYVJbupG3Xg

rovyko··on If the Tuition Doesn’t Get You, the Cost of Student Housing Will
Rent definitely affected my choice of school. With identical offers, I opted for a smaller tech-oriented university over the University of Toronto, which is either the top or one of the top schools in the country. I don't regret it, because rent in Toronto was insane and it's only getting worse. I'd have to commute 90 minutes to my parents' house with no time for a social life, and I'm super lucky to know that I even had that option.

And now rents in the small town are growing. Subdivided houses are torn down for luxury apartments, and with recent cuts to government loans, it might not be affordable for some low-income students.

rovyko··on GPT-2: 6-Month Follow-Up
>As part of our staged release strategy, our current plan is to release the 1558M parameter model in a few months, but it’s plausible that findings from a partner, or malicious usage of our 774M model, could change this.

This seems naive but I think it's a misdirection. Of course the model will have malicious users. Propaganda teams started testing its integration as soon as it was released. It's likely that OpenAI is counting on this for insights into HOW the model can be used maliciously. It's also possible that the model results have inherent trackable markers and OpenAI can later say that X% of social media posts were made using this model.

So what are the positive applications, aside from prettifying data like sports and weather reports?

Even with Skyrim's 800+ books, you frequently ran into the same book. Imagine libraries filled with plausible text that hides nuggets of lore seeded by developers. Along with more realistic text-to-speech this can allow games to support a large diversity of NPCs that have true radiant dialogue and sound more realistic than "I saw a mudcrab the other day".

With some modifications, I think models like this can outweigh even their nefarious applications:

Defense against text decomposition analysis. The model can be used to obfuscate writing patterns that can reveal a person's identity, either by randomizing form or standardizing it. Take your post and run it through the formatter to get the same idea and intent, but in a style that can't be traced to your other writing. Or you reform it into style of Ernest Hemmingway, like thousands of others.

Realtime plausible deniability encryption. Messages in a monitored chat can look like mundane conversation but contain encrypted messages. This would require the model accept seeds and work partially in reverse to diff two sets of text to reveal the hidden message.

In it's current form it doesn't look like it can do any of those things, but there's the potential.

rovyko··on New React DevTools
Why is that?
rovyko··on Show HN: An ad-free news website with crowdsourced summaries
>The UI is unappealing. I would prefer the default theme to be dark.

I made a stylesheet to fix a few of the glaring UI problems, as well as a sheet for dark mode: https://github.com/rovyko/hoxly-gui-patch-stylesheets

    * Horizontally align news item titles
    * New Items take up full margined-page width
    * Search input at the top of the page
    * All facts button has a pointer cursor
    * Increase button text size
rovyko··on An Orbit Map of the Solar System
A really impressive use of Python for visual graphics design! I wonder what kind of packages you'd need to reduce the amount of work done in external editors, probably something that can make SVG.
rovyko··on Lambda School wants to teach nursing
Oh is this the one with the website posted a few weeks back?
rovyko··on Downsized dwellings: Inside Tokyo's tiny living spaces
There's a good video from Living in a Big Tiny House covering one of these tiny Japanese apartments:

https://www.youtube.com/watch?v=TYVJbupG3Xg

rovyko··on Logic Puzzle: The Joy of Recursion
>Puzzle 2: The Lying Legislators

I believe this is the same question as the Blue Eyes one from XKCD [1], though with a more coherent premise.

1. https://xkcd.com/blue_eyes.html

rovyko··on Web Components could replace frontend frameworks?
CSS is still a pain in Web Components. Constructable stylesheets solve that problem, but they're still in the "Worth Prototyping" stage for Firefox.

https://mozilla.github.io/standards-positions/

rovyko··on The mystery of my desktop that locks up when it gets too cold
My Sony PS3 3D Display has the well-known problem where its screen shuts off for a few seconds every once in a while. I noticed it got significantly worse this winter, when I opened the window for some fresh air.

Did a few tests, and sure enough, if the room temperature is below 22C and the screen has been on for about 10 minutes, then it starts to shut off frequently. My guess is the ambient temperature is causing some metal component to contract and break a connection.

rovyko··on Morning Cup of Coding – A curated daily newsletter for programmers of all fields
It's not exactly coding related, but I really like the Orbital Index. The stories they choose are usually interesting and their blurbs are succinct enough to read during a few minutes break.
rovyko··on Betrayed by the Android UI [slides]
Interesting slides, I wish we could hear the presentation audio. What's going on in slide 22?
rovyko··on Ransomware Forces Two Chemical Companies to Order ‘Hundreds of New Computers’
Is flashing the BIOS and reformatting the machine sufficient to remove any virus that we know of currently? Or are there other hidden components that need to be cleared?
rovyko··on Generative.fm – Endlessly unique ambient music
Simple, but pleasant. This is how it starts. It might take some time, but I think most ambient music in video games will eventually be procedural.

EDIT: Just want to say that these are better than I expected. As good or better than about half the ambient music recommendations I get on Spotify.

rovyko··on Types Are Moving to the Right
Is there a name for side on which the type declaration sits? Left/right typed? If that's the case, I'd argue for back/forward or start/end to account for right-to-left languages.
rovyko··on The sharing economy was always a scam
>lots the transmission at 65000 miles

That's insane... What's better for wear on the engine, turning it off then on or idling in neutral?

rovyko··on Firefox Experiments I Would Have Liked to Try
Have you looked into Saka? It makes a lot of browser functions available from the keyboard.

https://addons.mozilla.org/en-US/firefox/addon/saka/

rovyko··on Hacker News Meetups
> Most of the groups use meetup.com

Can anyone suggests free alternatives? I want to set one up for Waterloo, Canada but don't want to pay for a plan when I'm not sure if an audience exists.

rovyko··on Starbucks' music is driving employees nuts
>There's no carolers, the smells aren't the same, the shops aren't the same

Growing up in Canada, I thought carolers and olde-timey Christmas themes only happened in movies these days. Are these traditions still alive in the UK?

rovyko··on Mozilla may treat Aussie staff as 'insider threats' to code base
Do you think the presence of a code review practices alone will be enough of a deterrent against agencies using devs for this purpose?

Even if you pressure someone to make a backdoor and they get caught, you've just exposed your intentions when it could have been easier to go straight to the company.

rovyko··on Someday your self-driving car will pull over for police
The same way a taxi driver will pull over for police when you're in the car?

I feel loss of agency in autonomous vehicles is far more obvious and expected than the one we experience with our data.

rovyko··on FastMail loses customers, faces calls to move over anti-encryption laws
Contents of the TOLA act in question: https://www.aph.gov.au/Parliamentary_Business/Bills_Legislat...
rovyko··on Mozilla may treat Aussie staff as 'insider threats' to code base
>... that individual employees could be targeted by law enforcement to make secret changes to systems

So with the TOLA act, who is under the Australian government's jurisdiction and can be compelled to do this? Only those residing in Australia? Any citizen anywhere in the world? Anyone with assets or interests that could be leveraged?

What does this mean for Australians seeking employment in other countries?

https://www.aph.gov.au/Parliamentary_Business/Bills_Legislat...

Page 1 of 2Next →