HN user

AReallyGoodName

340 karma

Blockchain, ethereum, crypto...

Posts9
Comments77
View on HN

Quite the opposite is true. If you are using the PCIe bus a lot you probably aren't making good use of the GPU.

A GPU has it's own processor and RAM. If you're transferring to your system RAM and back again often enough to max out x16 PCIe lanes you should fix that.

Socat is excellent too. Not as high performance as iptables but the command is very simple to use. More of a direct replacement for the program above.

If there's a lot of financial analysts and engineers saying "this isn't feasible" and they are being ignored then that's a bad reality distortion field.

Hyperloop One in particular comes to mind here. Some people say its feasible. Some say it isn't. Both have valid points.

I like his work. I just don't want to see Musk fail due to lack of focus on one particular part of the dream and a lack of people on his team willing to say no.

This combined with the fact that they now demand access to your facebook account on entry means I'm scared to post anti trump comments online. I need to travel between my birth country and my new home in the USA regularly. If I get a pro-trump homeland security agent (and it seems many of them are) scanning my phone. I fear I might be denied re-entry despite having a valid work visa.

I guess we'll be seeing more and more of this in the near future. I and other non citizens are now silenced. A few more laws like this to silence a few other anti-trmup groups and the USA will slowly creep into totalitarianism for fear of losing everything they have.

I'm just glad my birth country is Australia and I can happily return there before it gets really bad in the USA. The biggest problem I'm having is where shall I draw the line where I pack up my life here and return.

Getting Past C 10 years ago

Arrays and pointers in C already have that int. That's why sizeof() works. The issue is an extra if statement on every single array and pointer access.

Well having one aspect related to sun position (leap seconds) living in the raw seconds counter and all other aspects related to sun position (time offset, leap years, etc.) living in the human readable date formatting functions is unacceptable imho.

We either get rid of leap seconds in UTC time and treat leap seconds as a date formatting issue or we somehow get all OSes, libraries and applications to start using TAI time as their fundamental time counter instead (this is preferred but it's a lot of work, so yeah you're right about it being laziness).

Or i guess we can just continue living with the inconsistency of some sun position stuff being in the time counter and the rest in the date formatting functions (ick! there's a reason this is causing bugs all the time!).

Neurodiversity 10 years ago

In the case of extremely severe disabilities i think we can all completely understand that attitude. Those who don't understand or think it's weird have probably never had to care for someone with such a severe disability (i try my best to help out relatives who have a disabled child but i struggle to do it for more than a few hours at a time).

Compressed air will cut you. I'm more curious about the welder earthing one.

It's low voltage. The risk of a shock there is similar to the risk of shock from a car battery. It can happen in theory but realistically arc welding has some bigger hazards to worry about than the grounding connection (like the molten slag flying everywhere). Sure I wouldn't weld knee deep in salt water or whilst leaning against a metal wall but outside of ridiculous examples the grounding clamp isn't going to kill me.

When i weld the grounding connector often has a poor connection for whatever reason (usually due to weathering on the metal). The result is simply that the welder doesn't work well and i have to adjust the clamp to fix it. I don't suddenly die of electrocution.

Not a fantasy. In Australia contactless payment using smart cards is now everywhere, even in the small news outlets, food stalls and coffee shops. I bought lunch at a small shop just a minute ago with one.

For things like buying second hand cards we also have a pretty good online direct deposit system where you can just transfer money online.

Cash is losing the war here, check out the graph in the following article showing the dwindling usage of cash.

http://www.heraldsun.com.au/business/why-our-looming-cashles...

As a casual and unfit cyclist who doesn't break 10mph i think there should just be a "you can ride on the footpath if you're going at less than running speed" rule.

Question about this:

It's not possible for me to track all the 0 days for every piece of software and library that my servers run. One of my long running servers could have been backdoor-ed by a 0 day 6 months ago and i probably wouldn't know it. The servers are kept updated but 0 days don't care about that by definition.

What's the best practice here? Should we pre-emptively have our servers rebuild daily just in case a 0-day backdoored them?

Americans are really snooty imho. I suspect the snootiness is both the reason these houses exist (I have a bigger house than you) and the reason this criticism exists (I have a nicer looking house than you).

I feel like it's a rather toxic cultural thing to care at all about other people's houses. Likewise with cars. It's also something that's not nearly as prevalent in mainstream culture outside the US (snobbery is the domain of the upper classes exclusively).

I've found Lambda to be really ridiculously fucking cheap. We moved image resizing onto it and saved thousands a month.

Don't compare the cost of Lambda per 100ms to the cost of a virtual machine per month since Lambda only charges as you use it. You'd have to have the CPU pegged at 100% usage to make that a fair comparison. Mind you even if you took the cost of Lambda per 100ms and multiplied that out for a monthly cost it's still about the same as an EC2 instance of the same capacity. (Eg. if I had a 1GB Lambda running for a total of 1 month compute time in the uswest2 region it'd cost $32).

Oh and the cost of API gateway is $3.50 per million requests and the bandwidth cost is completely negligible for us (we redirect to the resized image hosted on S3, fronted by cloudfront). We get 3 million image resizing requests a day. That's over 30 per second. It would take a lot of VMs to handle that (image resizing isn't trivial). Or we could just pay the whole $11.50.

I have to ask have you done the math? Lambda beats everything in cost except for some funky solutions using unreliable and less scalable lowendbox.com services.

Note that it is important if you have suspension though as you'll have a much smoother ride if the mass on the other side of the suspension from you is minimised. If the wheel is heavy the opposite and equal force will be felt when going over bumps.

The suspension reason isn't relevant to lightweight bicycles but important to keep in mind for other bikes.

Resizing on the fly. Think of an API that gets an image and desired resolution and sends it. It's a common enough use case. Compare Lambda as the entry point of this API compared to another framework.

Any other webserver is simply get image off S3->Resize it->Send raw binary data to the user (and optionally cache the resized image if you think it'll be requested in that size again).

The Lambda flow is as follows. Get image off S3->Resize it->upload to S3 and then redirect the user to that image via a cloudfront URL.

Unnecessary steps caused by the inability of Lambda get binary data out through the API Gateway. Particularly from the users point of view. You double the number of requests they have to make to fetch images.

It can't do binary data.

You can redirect to a file the Lambda function writes out. But that sucks.

AWS Lambda is the perfect use case for something like dynamic image sizing. Except if you use it for that you'll force all your users to do a redirect when fetching images. No easy way to clean up when you do it that way either.

Well it's easy enough to transition into arrow and hamburger

ObjectAnimator arrowRotateAnim = ObjectAnimator.ofFloat(mDrawerArrowDrawable, "progress", 0.0f, 1.0f);

arrowRotateAnim.setDuration(Constant.NAV_ARROW_TIME);

arrowRotateAnim.start();

and vice versa on progress where mArrowDrawable is a DrawerArrowDrawable object. I set NAV_ARROW_TIME to 300 and it seems the same as what google has.

There's a few issues with this though. Take various animations such as the one on the toolbar that some Google apps have (the arrow that spins into a hamburger and back again). Easy to do if you're just loading different fragments into a Framelayout, impossible to do with activities as you reload the entire toolbar on an activity change.

It's a general problem in the Android world. Some things can only be done as an activity whilst others as fragments.

In fact this is a problem even on Googles own apps. Right now if i tap things in the nav panel of the Gmail app it's a crap shoot whether i open a fragment or activity. Things like inbox/sent are loaded as fragments. Things like settings are loaded as activities with a completely different loading in animation. Help is different again. Lots of different ways of loading in a view all coming from options in the same menu. It's pretty fucked up form a UI perspective.

Yeah easy. Unfortunately vector drawables are API21+ on Android. A large chunk of my users aren't on API21+. Google helpfully provides app compatibility with older versions by rasterizing to all possible dpi sizes during the gradle build process which makes your apk huge of course and defeats the purpose of vector drawables. So you probably want to try a third party library instead of vector drawables. The most popular one seems to be badaboom/androidsvg. It requires setup code on every imageview to load. So you probably want to use a custom view to make it easier and avoid repeating code everywhere. Of course then you use other libraries that aren't setup to use those custom views and your back to manually rasterizing in code. Easy!

The person you replied to was talking about the unfortunate situation of some communists and socialists supporting Hitler over the respective competing party. It's analogous to Bernie supporters saying they'd vote Trump over Hillary or vice versa.