AVG Announces Invisibility Glasses - <AUTHOR> http://now.avg.com/avg-reveals-invisibility-glasses-at-pepcom-barcelona/ <comment><USER2> Speaking of IR... Not about privacy, but DIY medical stuff.

My wife suffers from restless legs syndrome. Pretty much, whenever she goes to bed, her legs feel as if they have ants crawling on and inside them. I know that I can use massage (she taught me, she's an MT) to reduce the restless feelings, but it's just a stop-gap. What causes it?

Turns out, its some -NO precursor that appears to cause this. Why does this precursor build up? I have no clue. But getting rid of it does alleviate the pain.

How I found to get rid of it, a medical paper said that NIR light is found to penetrate in the skin and is enough energy in the photons to break up the precursor. The medical paper was using a grid of low power IR lasers, with a total of 3W dispersed over a 12inx6in rectangle.

I made a 30 IR led (matched the frequency of IR from the paper) that outputted 3W of light. I use it on her when her legs acts up, and it settles them down. Usage over a week gives her days of rest from RLS.

<comment><USER3> Do you have any details on this build? My father has RLS and nothing seems to work for him. A quick google shows me you can buy the units used in the study, but they are quite pricey.

<comment><USER2> Sure do.

Scientific article I based my device on: [http://www.ncbi.nlm.nih.gov/pmc/articles/PMC2936319/](http://www.ncbi.nlm.nih.gov/pmc/articles/PMC2936319/)

"NIR has a wavelength of 880 nm to 890 nm"

"Researchers hypothesize that the success of NIR treatment lies in its ability to increase bioavailability of nitric oxide (NO) in the lumen"

"890 nm wavelength light, pulsed at 292 times/s, with a power output of 600 mW/cm2"

"The mechanisms with which NIR can alleviate RLS symptoms are not clear. One supposition can be made: light has been shown to generate NO in the endothelium, which through a cascade of events leads to vasodilation. Vasodilation is also the result of exercise, one of the few non-drug related treatment options that decreases RLS symptoms."

The above is the basis of my research. From this, I can make a device that does roughly this.

_____________________________________

My Bill of Materials are the following:

         12v @500mA wall wart
         30 http://www.digikey.com/product-detail/en/TSHF5410/751-1211-ND/1681346  IR LEDs
         barrel jack to fit wall wart
         perf board to fit LEDs
         project box
         IR-transparent acrylic (window in project box)

I used a scrounged wall wart (free), the LEDs are $20, the barrel jack was scrounged (Free), the perf board was $5, the project box was $9, and the acrylic was scrounged (Free). Total cost for non-scrounged was $34. I'm also part of a hackerspace, so scrounging was easy for me. I also used a bit of hot glue to make smooth interface where the skin would touch.

The circuit design is here: [http://imgur.com/5Op2ndU](http://imgur.com/5Op2ndU)

Solder them together through perfboard, and put in project box. Cut out a window on the box and put in the acrylic window. Now, all you need to is plug in the barrel adapter to the wall wart, and it works.

This is what I use. It puts out roughly 1.35W of IR light. I misremembered about using 3W. But this works, as it's a reproduction of my build.

<comment> bjelkeman-again Very very interesting. I have a whole family that suffers from the same, five siblings. Now we need to try that. Do you have a photograph of the contraption you made?

<comment><USER2> I'd be glad to. It's at home at the moment. I'll probably, with my wife's permission, send it up to my github.

Also, feel free to contact me. [https://keybase.io/jwconway](https://keybase.io/jwconway)

</comment></comment></comment></comment></comment><comment><USER4> They're only 7 years late.

[https://www.schneier.com/blog/archives/2008/07/sunglasses_th...](https://www.schneier.com/blog/archives/2008/07/sunglasses_that.html)

<comment><USER5> Its my understanding that face recognition is tough to crack on a mass surveilance level. People wear hats, glasses, sunglasses, scarves, etc on top of things like different hair styles, different glasses frames, etc. CCTV quality isn't good enough to identify faces and even high quality video can be tricky if you don't get enough high quality frames of the person's face looking straight at the camera.

It looks like identifying people via their gait was a bit of a research hurdle not too long ago and there are a lot of articles from around 2012 that claimed this problem has been solved. The idea was low quality CCTV footage really can't be used to identify faces, but can be used for gait analysis. I wouldn't be surprised if there was a signature gait database somewhere in use by intelligence and law enforcement services. The same way the Stasi kept a database of people's scents in jars.

Now with everyone carrying a cell phone, I imagine immediate identification is easier than ever. IMSI-catcher devices like the Stingray are trivial to implement. Phone carriers easily give up information about their customers, including GPS history, sometimes even without a warrant. License plate tracking is common as camera deployment and plate OCR is very affordable for many municipalities. Tracking via toll system RFID transponders is common as well.

Not sure who these glasses are aimed at. It looks like anti-security theater designed to get press and lighten wallets.

</comment></comment><comment><USER6> Not a bad start, but hopefully something better comes later. This would just be an arms race scenario- they'd only have to develop algorithms to work around this, and worst of all, they still have your actual picture on-disk so they have all the time they desire to make it work.

I seem to remember an anti-camera system deployed at movie theaters years ago which would look for camera sensors, and then blind them with IR lasers. While probably not as portable, something precise rather than the shotgun approach they're using here might work better. Bonus: you don't need to have it mounted to your face, either- it could be attached to your hat, shoulder, chest, etc.

<comment><USER7> > anti-camera system deployed at movie theaters years ago which would look for > camera sensors, and then blind them with IR lasers

I think it is unlikely. IR lasers can still damage eye sight.

<comment><USER5> Looks like shooting IR at the audience is how some/most of these systems work:

[http://archive.wired.com/entertainment/music/news/2004/11/65...](http://archive.wired.com/entertainment/music/news/2004/11/65683?currentPage=all)

but yes, it does sound like its probably like plain old IR light and not a laser.

</comment></comment></comment><comment><USER8> Doesn't defeat the face detection in libccv:

[http://imgur.com/HNPBNTJ](http://imgur.com/HNPBNTJ)

[http://imgur.com/P3XnlwK](http://imgur.com/P3XnlwK)

Edit - I don't mean to kill interesting conversations around this, but be aware we're looking at an implementation that simply doesn't work, so we should only really be talking about similar but different possible approaches. Anything like this is so fundamentally flawed as to _not even currently work_ against currently used algorithms.

So if we want to go down that road, what more extreme things might we need to do?

<comment><USER9> The article does not claim that the glasses prevent face detection. It claims that they prevent face recognition. These two concepts are different.

Face detection - determine the location of a face or faces in an image.

Face recognition - given a location of a face in an image, correctly predict who's face it is.

Check out the OpenCV Facial Recognition Tutorial for more info: [http://docs.opencv.org/modules/contrib/doc/facerec/facerec_t...](http://docs.opencv.org/modules/contrib/doc/facerec/facerec_tutorial.html)

<comment><USER8> > The article does not claim that the glasses prevent face detection.

Their first image seems to be showing the difference between detecting and not detecting a face ("Facebook detects a face" and "No face detected").

Comments like this, too:

"They claim to break face detection when the lights are on."

So I assumed they were claiming it breaks face detection.

</comment></comment></comment><comment><USER10> This defeats regular face detection but you are now literally wearing a big, glowing sign that says "this individual is hiding his/her face!".

<comment><USER6> Like many privacy tools, this would work best if everyone was wearing them.

<comment><USER11> It'd be more effective for everyone to vote for people that intend to break down and illegalize all of these facial recognition things, if we're all going to organise something anyway.

<comment><USER6> That's a bit tougher though.

For one, privacy concerns are just one _very_ small part of what people may be looking for in an elected official. So small that most don't even have an official stance on the matter, aside from canned politician spin like "I value the privacy of all citizens" that actually means nothing. On average, I'd say that most people would still rate economic and diplomatic policies much higher.

Like just about everything else, this boils down to an education problem. Not just for the voters, mind you- it's even more important to educate our elected officials and judges. This way, they'll be able to make rational, informed decisions when the NSA comes asking for more money / power. (This is of course assuming the NSA doesn't have huge caches of blackmail evidence on the officials making the decisions...)

</comment></comment></comment></comment><comment><USER12> I thought April Fools arrived early this year...

<comment><USER13> I agree. If it's _not_ a joke, they should have tested those pictures on Facebook's facial recognition system.

I strongly suspect even a simple system will easily still recognize that guy.

<comment><USER8> I think they tested the first one, and facebook failed, although both approaches have no effect against the libccv face detector

[http://imgur.com/HNPBNTJ](http://imgur.com/HNPBNTJ)

[http://imgur.com/P3XnlwK](http://imgur.com/P3XnlwK)

</comment></comment></comment><comment><USER14> Although it is a good start, I wonder if the effect of IR LEDs can be solved by filtering? I mean, can someone develop a firmware or use color filters to filter out infrared light?

I think the filtering may be done using better Bayer filters to filter out infrared, but I know almost nothing about digital photography.

<comment><USER15> Yes, almost all cameras above the dollar range will include filtering for this frequency. You can find out by pointing a TV remote at your phone camera and seeing what the impact is. My iPhone can't see the IR emission at all with it's rear camera, the front camera doesn't have a filter and gets absolutely blasted. It would be devastatingly effective against monochrome CCD cameras, where the same LEDs as used in the article are used for invisible illumination of a scene.

[https://i.imgur.com/zkI5p0B.jpg](https://i.imgur.com/zkI5p0B.jpg)

[https://i.imgur.com/BfRWTbq.jpg](https://i.imgur.com/BfRWTbq.jpg)

If I remember correctly, a cut piece of floppy disk does a reasonable job of being a blocking filter for nearly everything that's not near IR, though that's less of a handy thing to know these days.

<comment><USER5> The IR nut is tough to crack if your camera does night vision. Those cameras with a ring of LEDs around them? They're IR transmitters. The camera is designed to detect IR, so it can't filter it. This is a popular method of seeing in the dark and is used on systems way more expensive than dollar store close-outs.

<comment><USER16> Would it be that difficult though to have a modified Bayer filter with an RGBI array instead of RGBG?

You would have to use different dyes for all pixels, since the currently used ones let IR light pass, but it doesn't sound that difficult to do (since we already have both IR-pass and IR-block filters).

</comment></comment></comment></comment><comment><USER17> Are they trolling? Those are just some glasses with ir light and ir reflective coating. These will make your face more visible to cameras in the dark. Also facial recognition algorithms can easily be adapted to work around the stupid glow. They only need like 10% of your face anyway.

<comment><USER18> This is just a 1% solution, which may be enough to defeat mass data collection as long as it remains niche. For a bigger effect, carry light strong enough to saturate even a HDR camera.

<comment><USER2> If you remember the old (VHS) Macrovision, it used a pulsing contrast to mess up automatic gain control circuits. A good way to defeat this is by putting a POT on the AGC so you can tune it manually.

A way to apply this to the glasses: put a IR strobe on. Pulse it at .5s, with a .05s IR led on time.

You should be able to get away with this using an array of IRleds, battery, and a 555 timer.

</comment></comment></comment><comment><USER19> I lived in a city with red light cameras, and I considered building a license plate cover with the same principles as a tiny form of non-violent protest.

<comment><USER20> Here in Brazil they are common, and I protest by not running red lights. Works every time!

<comment><USER21> 'Do you have anything to hide?'

</comment></comment></comment><comment><USER22> I don't think is much new, they've been made before...

[https://www.schneier.com/blog/archives/2008/07/sunglasses_th...](https://www.schneier.com/blog/archives/2008/07/sunglasses_that.html)

Although I think it was meant mainly as a way to prevent you getting recorded on CCTV.

</comment><comment><USER7> Surgical mask seems like more effective.

<comment><USER11> That and a pair of sunglasses

</comment></comment><comment><USER23> If you wear a pair of those glasses, everyone is going to know who you are.</comment>


Metaprogramming JavaScript (presentation slides) - <AUTHOR> http://www.slideshare.net/danwrong/metaprogramming-javascript

<comment><USER2> The slideshow is a bunch of JS introduction, and barely any "metaprogramming". If you are really looking for a good JS read, check out this article:

[http://simon.incutio.com/slides/2006/etech/javascript/js- rei...](http://simon.incutio.com/slides/2006/etech/javascript/js- reintroduction-notes.html)

<comment><USER3> Thanks. That was a good link. I have bookmarked it.

It's much more explanatory, though. I believe the intent of the main linked article is a presentation giving more of a tour to what is possible. The author makes clear at the end that the reader might not get it all -- it's just an overview.

I didn't find much difference in terms of metaprogramming, however. Were there any concepts in your article that weren't mentioned in the first one? I might have missed it.

I'd use the presentation as a way of glossing over the high points, and then refer somebody to your link as a way of figuring out how it all works.

<comment><USER2> There aren't new concepts, just actual explanations of what the presentation is talking about.

"I'd use the presentation as a way of glossing over the high points, and then refer somebody to your link as a way of figuring out how it all works."

Probably a good strategy.

</comment></comment></comment><comment><USER4> "Nearly everything is a hash... everything else is an Object"

Huh? Objects _are_ basically hash tables/associative arrays in JavaScript...

</comment><comment><USER3> This is a great presentation including small samples of Javascript showing off all the cool parts. (I'm adding this comment to catch folks that might have missed the article post but are reading the new comments page) It's a cool resource for folks wanting to do a quick check of their JavaScript programming chops.</comment>


Robinhood will retool checking product following scrutiny - <AUTHOR> https://finance.yahoo.com/news/robinhood-retool-checking-product-following-034523132.html <comment><USER2> Earlier submission of same article (on different URL):

[https://news.ycombinator.com/item?id=18690873](https://news.ycombinator.com/item?id=18690873)

<comment><USER3> Thanks, we've moved the comments there.</comment></comment>


Git v2.2.0 released - <AUTHOR> http://lkml.iu.edu/hypermail/linux/kernel/1411.3/02881.html

<comment><USER2> The fast-export --anonymize item is interesting. I've used a few tools professionally that I've been unable to feasibly report some bugs for, because any time I produce a log file (or whatever) it's filled with file names or email addresses or function names or code snippest or paths or whatever. Or if it's an example file, it contains copyrighted information that one can't just go giving away to 3rd parties.

Had there been some kind of anonymization option, on the other hand, there'd have been no problem. As it is, I just have to produce some hand-wavey bug report, that's as accurate as I can make it - that then presumably gets put on the shelf with all the other random unclassifiable oddities that nobody has time to look at properly. Because they're too busy dealing with the bugs that actually came with data.

(Of course, sometimes the data itself _is_ the problem, and then this wouldn't help. Then other times, the system in question has faulty RAM. This wouldn't help with that either.)

</comment><comment> andrey-p I love the slightly anthropomorphized language used in this.

> "git archive" learned to filter what gets archived with a pathspec.

> "git mergetool" understands "\--tool bc" now

> The pretty-format specifier "%d" [...] gained a cousin "%D"

<comment><USER3> Yes, that's awesome. They've always been doing that. I love that too.

</comment></comment><comment><USER4> And once again there is a need for a friendly reminder: If you release a bit of software and wish the audience to pay more attention than they would to any average maintenance releases:

Put something in the title of the release announcement to explain what makes this one special.

Try to do it in a way that makes sense to someone who rarely ever even uses your software.

<comment><USER5> That seems a trifle petty: Just skimming through the list of updates and I'm already impressed by the content, and I've not even gotten to the fixes yet.

There is no "one-liner" that will capture this, save perhaps something near- linkbaity like "git 2.2.0 - almost a hundred contributors, 20 brand new, with dozens of updates and dozes of fixes! Whew!"

Having said that, the announcement of a point release like this isn't the place to appeal to those who are not git users: This notice is aimed squarely at those who are git users and need to know whether or not they should upgrade.

Marketing communication is all about understanding your market, its segments, and the messaging each segment needs. This announcement isn't for newbies or notbies.

If there is a grain of truth in your comment, then it is that a separate announcement is needed, a more general press release, aimed perhaps at the wider community, to whit:

Team responsible for world's most popular distributed revisioning system announces update

Git, the world's most popular distributed revisioning system, has been updated, according to announcements released this morning to the development community.

The new release features contributions from over 70 contributors, 20 of whom mark their git release debut. This version, dubbed 2.2.0, contains approximately two dozen fixes to the 2.1 release as well as several dozen backwards-compatible new features.

The development team is thrilled and proud of their work and eagerly awaits community feedback.

<Insert standard description of git here>

<Insert list of major git projects here>

<Insert upgrade roadmaps for GitHub and other git-as-a-service providers>

<Insert standard description of revision control here>

<Insert standard "considering switching to git? look here"?>

<Insert standard "new to git? look here">

(All of the above CC-BY-SA, feel free to use as desired.)

<comment><USER6> > something near-linkbaity like "git 2.2.0 - almost a hundred contributors, 20 > brand new, with dozens of updates and dozes of fixes! Whew!"

Titles like that are linkbait when the document linked is not actually worth the hype of the title. Actually descriptive titles like your example are great titles in my opinion, except possibly the last bit with exclamations.

</comment></comment></comment><comment><USER7> And still the windows build remains 1.9.4. Am I missing something?

<comment><USER8> The Windows build is made by the msysGit team ([https://msysgit.github.io/](https://msysgit.github.io/)), which is a separate team with a chronic lack of manpower.

The Git situation on Windows is somewhat like openssh versus portable openssh, or libressl versus portable libressl: it's originally developed for one system, and a separate project ports it to another system. It's a bit harder for Git on Windows, since Git was written expecting a POSIX system (parts of Git are written in shell or Perl, for instance), and Windows is different enough to give it trouble.

If you want Git on Windows to be more up-to-date, give them a help; I'm sure they'll appreciate it.

</comment></comment><comment><USER9> And yet on OSX Yosemite:

       $ git --version
       git version 1.9.3 (Apple Git-50)

<comment><USER10> Trivial to get an newer version though, for example through homebrew.

Here is what I have, currently (haven't updated in a while)

        $ git --version
        git version 2.0.3

For windows, it is another matter, seems officially stuck at 1.9.4 since forever ([http://git-scm.com/download/win](http://git-scm.com/download/win))</comment></comment>


Collection of .NET Framework and Visual Studio Posters - <AUTHOR> http://www.devcurry.com/2010/06/collection-of-net-framework-and-visual.html

<comment><USER2> I've never, ever, understood these things. In what way am I helped as a developer by looking at a picture with some high-level namespaces?

<comment><USER3> I've always likened these posters to the legal books kept on law office bookshelves. It's 2010 and I'm not sure I want to set foot in the office of a lawyer billing $200+/hr if they're seriously still sifting through tomes.

I know what I'm talking about...you see all this wood pulp at my disposal?

</comment></comment><comment><USER4> I'd like to be clever enough to emulate Cato the Elder, and come up with a short motto I could add to comments on all articles .NET related which encapsulates the following:

MicroSoft, good work with the .NET Framework, C#, F#, and LINQ, but if you want to keep Windows relevant, make all editions of Visual Studio free and open sourced. That includes the Professional, Tester, and Architect versions. It's not enough to offer "Express".

So maybe my motto should be "Open source Visual Studio!". (I sure hope I don't get down-voted or banned if I start doing this.)

<comment><USER5> Why does the editor have to be open source? I think you might have an argument if you wanted .NET and other proprietary software related to development open sourced and available on all platforms but an IDE is not something that needs to be open source (though extensibility is always good).

<comment><USER4> 1) More important than open source, it needs to be free. It's danged expensive, and the version with the full compliment of testing tools is even more expensive. There are several very decent free IDE's not from MicroSoft, and they are primarily aimed at non-MS environments. It's in MS's interest to promote development in their OS talking to their family of software products.

2) Open source because MS still hasn't made it a good IDE for Javascript development. Yes it has Jscript Intellisense (nice), but you can't collapse Jscript by {} in the editor. This hampers it as a full-fledged web development IDE if you're going to do any more than trivial JS development. If it were OS, maybe someone would fix this.

</comment></comment></comment><comment><USER6> I wish I had printed versions of those for my office. They might not be useful for day to day development, but it serves as a warning (of my nerdiness) to others when they visit.

</comment><comment><USER7> Funny. For a second I thought this was a public shaming campaign targeting hacker-news members that still work with "evil tools".

<comment><USER8> I get tonnes done with my evil tools.

<comment><USER7> Jeez, Louise. Again: It was A JOKE. Why do you think I put it in inverted commas?

<comment><USER8> I wasn't freaking out on ya man! More a statement that I don't mind if people know I use (and love) .Net.</comment></comment></comment></comment>


Dakota Access pipeline: 300 protesters injured after police use water cannons - <AUTHOR> https://www.theguardian.com/us-news/2016/nov/21/dakota-access-pipeline-water-cannon-police-standing-rock-protest <comment><USER2> Honestly, this project needs to end.

Average Americans don't support it, it lacks the Congressional approval it'd need, and oil is on it's way out (either by discontinuing the technology that needs it, or just flat out running out of usable oil reserves in 50 years).

I have no clue how a private military force ("the police" referred to in the article is more militarized than a SWAT team is) is even allowed to operate on American soil and attack American citizens.

<comment><AUTHOR> I didn't expect this story to go anywhere here, but was too irritated to not post it anyway. As for your befuddlement regarding paramilitary nonsense in America; it is easily answered by contemplating the terrible dangers posed by high-profile terrorists such as Amy Goodman, who'd wantonly inflict grievous mayhem upon our freedoms if not for the glorious impedance of SWAT.</comment></comment>


Xbox One and Windows 8 app platform unification teased - <AUTHOR> http://www.theverge.com/2013/6/27/4470658/xbox-one-windows-8-apps-build-2013

<comment><USER2> Wait if the Xbox becomes a PC, then what's the point of the Xbox?

Surely its better in that case to just stick a PC in your living room, hook it up to your TV, and have the full flexibility of Windows! And instead of throwing out the whole thing every few years, just upgrade the GPU once in a while.</comment>


Show HN: Get Instant Feedback on Your Coverletter with AI - <AUTHOR> http://app.coverletter.io/editor <comment><AUTHOR> Hey HN,

I just built this as a sideproject with inspiration from [http://textio.com](http://textio.com) after getting frustrated with the lack of feedback and haphazard advice for coverletters on a multitude of blogs. I built it using Flask, SpaCy, Textacy and NLTK with a bunch of heuristics that I took from writing blogs and form talking to experienced manager.

This is just an MVP so it isn't super fast and is missing a few nice-to-have features like HTTP.

</comment><comment><USER2> Why am I not able to access the link? Is the tool live?</comment>


How Google's Self-Driving Car Works - <AUTHOR> http://spectrum.ieee.org/automaton/robotics/artificial-intelligence/how-google-self-driving-car-works/ <comment><USER2> You may giggle at Googles attempts to catch up with Facebook, but looking at this video.. boy, they are way ahead. Google isn't so much a search company, its an innovation company. They are already building the next trillion dollar industry while Facebook is optimizing sharing cat pictures.

<comment><USER3> >> _They are already building the next trillion dollar industry while Facebook is optimizing sharing cat pictures._

What makes you think that sharing cat pictures isn't a trillion dollar industry?

Last time I check photo sharing apps and bird-in-pig games fetch and sell for more money than life saving cancer drugs.

</comment></comment><comment><USER4> It is normal for pedestrians to look for eye contact in order to know if a driver will yield the right of way or simply will accelerate and pass (in light less crosswalks). In dense pedestrian cities (I am from Spain) it is very usual to have some guessing and false start stop between the pedestrian and the driver, nobody seems to know who is going to yield finally. I wonder if this is been thought and how you'll signal the car's intention to a pedestrian?, maybe a forward braking light?. It could be that automatic cars will be much better yielders than a human driver.

<comment><USER5> It makes sense for the self-driving car to yield to pedestrians all the time. So if you see that there is no driver, you assume it will stop until you are out of its way.

There will be no more awkward social guessing games!

<comment><USER4> There is a second part on it. How will cars behave when they are driving along a crowded street in a place where people crosses anywhere and changing directions and intentions very fast. I don't think there will be dangers to pedestrian. But it's going to be a tought problem avoiding false emergency breaking. Once more you have to rely on visual contact to know what are the real intentions of people. Crossing, waiting for the car to pass, simply unaware of the car coming, going to pick something that fell at the border of the street but no intention to cross. Not an easy task!

Also it is strange they are not working on a kind of transponder, that could be used between nearby cars to coordinate maneuvers(maybe I missed it on this article, but I think I read about somebody was developing it) . It will be usefull once robocars are more common.

<comment><USER6> My guess is that originally self driving cars will be mainly used on highways and take you to the metro hubs. Once you reach a very populated metro area, you will use the local public transportation.

<comment><USER7> They would probably BE the public transportation. We need large buses because drivers aren't flexible enough to deploy, and you need to have enough capacity to meet peak demand. If you can have smaller driverless vehicles, and just put more of them on the road during peak hours, it's much more cost-effective (and environmentally friendly) to have smaller capacity vehicles. I doubt we'll see more than 10 people per public transit vehicle once driverless transport becomes the norm.

<comment><USER8> A diesel bus gets 6mpg --- you only need 10-15 people on one to match even the most fuel-efficient of cars in terms of environmental friendliness, unless you're referring to something else..

<comment><USER9> That's assuming there is only 1 person in the car. A car that does 60mpg with 5 passengers can move people 300mpg (of course you will lose some mpg due to the extra weight)

</comment></comment></comment></comment></comment></comment></comment><comment><USER10> _Everything_ Google does feeds back, somehow, to data mining.

How does self-driving cars fit in to Google's plans?

ETA: Downvoted for asking a serious question? WTH?

<comment><USER11> What do you think a bunch of people in self driving cars with smartphones or personal wifi hotspots are going to do? Surf the internet, and therefore use more of Google's products. It's similar to Chrome or Android in that it enables more people to use Google's core services which they make money off of.

<comment><USER10> Sensible answer, tnx.

Anyone play with the numbers? average web use vs. average AdWords profit vs. typical commute?

</comment></comment></comment><comment><USER12> I want to believe this is the future. Maybe not from Google, maybe from other companies, but self-driving cars are an amazing idea. Put a 100mph giant piece of metal in the hands of humans, on the other side, is not a smart idea...

</comment><comment><USER13> Once legislation is updated to allow self-driving cars in most parts of the world, I wonder how profitable self-driving cars could be for Google. About 77 million cars were produced in 2010. With the appropriate licensing, a percentage of that could make a very nice profit. I should buy some Google stock :)

<comment><USER14> I don't see what Google's role is going to be, aside from pushing forward legislation for unknown reasons. The auto manufacturers don't need them for the technology and research... they've all had access to that for just as long. We'd have self-driving cars today if the public (and regulators) were ready for it.

But they're not and aren't going to be overnight; what makes more sense is to gradually introduce the features a little at a time so that the move to complete autonomy is a small step instead of a leap. First, automatic parking. Then, collision detection warnings. Next, lane assist that steers you back into the lane when you drift. In the next few years, you'll start seeing "smart cruise control" that will drive for you on well-marked roads in mapped areas.

"Cadillac To Release Self-Driving Cars By 2015"

[http://www.inquisitr.com/227496/cadillac-to-release-self- dri...](http://www.inquisitr.com/227496/cadillac-to-release-self-driving-cars- by-2015-video/)

Maybe 10-15 years from now we'll be at the complete autonomy point.

<comment><USER15> I don''t know. It is my impression that traditional companies are not able to produce complex software. I guess there are many paradigms that you have to break to become a software company. It seems to me that is the reason why cell phone companies ended up buying their O.S. from google.

<comment><USER16> > It is my impression that traditional companies are not able to produce > complex software.

What gave you that impression?

What do you define as a non-traditional company?

<comment><USER13> I think OP defines non-traditional in this instance as software companies.

While I believe there's room for other companies to develop self-driving navigation systems, I think the Android example is pretty apt.

It's interesting to think about when self-driving cars will actually be in stores. By then, all navigation systems will meet strict safety guidelines and some standardised tests.

If all self-drivers are equally safe, the AI's driving style will become a differentiating factor. It seems to me like Google has an advantage in this type of development, although the future can certainly prove me wrong.

</comment></comment></comment></comment></comment><comment><USER17> I would love to see these in a city like SF. It's a small city (geographically), but we spend $1B/year on MUNI, which carries about 700K passengers/day. Put together a fleet of, say, 5000 such autonomous vehicles that take you door to door, for the price of a MUNI ticket. Wow. That would be something.

<comment><USER18> If I do the math, you will need many more than 5000 vehicles. 700k trips with 5000 vehicles is 140 per vehicle per day, say 50 in morning traffic and 50 in evening traffic, the other 40 in-between. Even assuming 5 people in e car at each trip, that means 10 round trips from suburb to the office per car.

I guess you will need at least 100k vehicles, but with that number of vehicles, that $1B per year starts to look cheap ($10k times 100k = $1B)

<comment><USER19> Maybe cars for the long tail routes, and hours?

</comment></comment></comment><comment><USER20> Given the amount of stuff going on it made me skeptical of GM's claim they would have a self driving car available for sale in 2015.

The Google stuff is pretty cool, I notice they don't show the early videos of people running around the parking lot trying to get it to stop :-) But such things are to be expected in development. This is a technology I look forward to as it would simplify a lot of things.

</comment><comment><USER21> I'd like to see some self-driving cars in a high-speed chase or race.

Google and NASCAR produced a joke video about self-driving race cars:

* Video: <http://www.nascar.com/video/none/none/120331/cup-mar-google/>

* More info: <http://www.google.com/racing/>

<comment><USER22> Already done, 2 years ago by Audi [http://www.engadget.com/2010/11/21/autonomous-audi-tts- scale...](http://www.engadget.com/2010/11/21/autonomous-audi-tts-scales-pikes- peak-in-27-minute-climb/) Some competitive jockeying would be fun though!

</comment></comment><comment><USER23> > With its full 360° horizontal field of view by 26.8° vertical field of view, > 5-15 Hz user-selectable frame rate and over 1.3 million points per second > output rate, the HDL-64E provides all the distancing sensing data you'll > ever need.

That's pretty interesting. I would have thought that they needed data at a faster rate than 15fps.

<comment><USER24> That is interesting! Looking into it, the estimated response time to an unexpected event for an average human driver is 1.9 seconds (i.e. time to notice, look, evaluate, decide, react).[1] Of that, 50 ms or 1/20th of a second goes to just processing the visual chemical stimulus into a usable signal.[Awesome Dinosaur Comics link] So if the robocar is getting a frame every 66 ms, that's probably not a significant factor making it better or worse than a human driver -- it's certainly not the key factor to optimize. On the plus side, the robocar is constantly looking in all directions rather than having to refocus on unexpected events, and can send signals to the car instantly, so it saves a couple hundred ms on each end. It probably ends up with a good bit more time than an average human to make decisions.

Of course the robocar isn't allowed to drive like an average human. It'll have to drive like a perfect human. Seems like that should be doable.

[1] [http://books.google.com/books?id=YkNY6gjxnMIC&lpg=PA396](http://books.google.com/books?id=YkNY6gjxnMIC&lpg=PA396) [Awesome Dinosaur Comics link]<http://www.qwantz.com/index.php?comic=1806>

</comment></comment><comment><USER25> I wonder how long will it take till the price of something like this gets to reasonable levels. The lidar and other sensors probably won't get cheap anytime soon. Imagine the costs of Google having to drive through all the places first, mapping them. Then the massive insurance until its proven that self-driving cars are safer (and then it will probably get expensive again after a first accident)

Perhaps it would make sense for government to step in like it did with electrical cars.

Edit: It seems the LIDAR they use costs 75000$. :-/ [http://eole.ecam.be/claroline/backends/download.php?url=L0dv...](http://eole.ecam.be/claroline/backends/download.php?url=L0dvb2dsZV9jYXItc3VtbWFyeS5wZGY%3D&cidReset=true&cidReq=AN52)

<comment><USER26> Not to speak like a party-pooper, but could someone potentially mess with this LIDAR system by aiming a very bright IR beam at the device, if not a matching laser itself?

Bringing down the cost of the LIDAR will be one major task, the other will be making this untouchable in the environment, IMO.

<comment><USER23> > Not to speak like a party-pooper, but could someone potentially mess with > this LIDAR system by aiming a very bright IR beam at the device, if not a > matching laser itself?

You could probably screw up the samples that would be taken from wherever your beam hits on the mirrors. But you could also shine a laser in someones eyes while they're driving and seriously impair them as well.

<comment><USER27> You _would_ screw it up - but only that mirror. The systems are designed for safety - the car would likely stop.

<comment><USER23> But what about reflective objects? The roadway is covered with different degrees of weirdly-reflective surfaces. Surely those beams land in places where they shouldn't (on the mirrors), and surely the car doesn't stop every time.

<comment><USER28> LIDAR works _through_ reflections. It essentially paints out the surrounding area with laser pulses and then measures the time for those pulses to come back. Since lasers travel at the speed of light, this time-to-return is quite small and hence they need quite accurate clocks (which is where a lot of the expense comes in).

That being said, laser range-finding works well on diffuse surfaces; this is because when diffuse surfaces reflect, they reflect the incoming light in a broad hemisphere (or cone) which sends the laser pulse out in many directions. Consequently, the surface to measure can be at a variety of angles and still be picked up by the LIDAR sensors (the sensor doesn't care about strength, only time-to-return)

So in terms of "weirdly reflective" surfaces out there, almost everything is diffuse enough for LIDAR to work well. Car hoods, carbon fiber, chrome wheel covers, etc. The only exception is glass, where generally lasers travel straight through and don't return to the sensors. So LIDAR actually detects "holes" in these situations, as if other cars were driving with no windshield an all their windows down.

So the only real risk would be a large plane of glass in the middle of the highway with completely normal road behind it. LIDAR would miss the glass, and the cameras would not be able to see it either. Most real drivers would fail at that too though :D

<comment><USER23> I guess what I meant was, surely there are weird surfaces that have multiple bounces. Or light being emitted could bounce between 2 cars and back to the sensor...or off a shop window (at a high angle, fresnel reflection), back onto something else, and back into the sensor. This data would come back into the sensor and it wouldn't be expected.

So surely the automated car, when it sees data it does not expect, does not stop, because it must see data it does not expect often through multiple bounces, right?

<comment><USER28> Sure, the situation you described certainly happens and is just considered a general noisy measurement. The car could detect empty road one second and all of the sudden some small object _right_ in front of the grill at the next frame. To avoid this "freakout" situation where the car slams on the brakes every time a noisy measurement comes in, all the data is passed through a particle filter (or Kalman filter) first before being processed by the AI.

The transition model of the cars environment is known, so it can reason that "there is a very small chance this reading represents a real object and is not noise, because i did not detect anything near this position over the last 20 frames, so I'm going to assign a very low probability to it." Hence you can clean up the data really well because you're measuring an outdoor environment, not a meteor shower (or anything else where objects could appear and disappear every frame due to high velocity).

</comment></comment></comment></comment></comment></comment></comment></comment><comment><USER29> I wonder if they will eventually license the self-driving software in an Android-like model?

<comment><USER27> Doubtful. Most of these companies want to own the tech. I'm actually concerned they won't be able to sell it if they tried - Chrysler is actively developing a self-driving system that they hope to deploy in 2 years.

<comment><USER30> Really? I'm no expert, but this seems like a market where it'd be natural for there to be only a few major players, rather than every manufacturer having their proprietary implementations. Why would you build an in-house system rather than buy one? Generally because buying is more expensive in the long run, because you can build a better one, or because keeping the expertise in- house allows for more chances of integration.

The expense idea makes no sense. This is software we're talking about, so the marginal cost is always going to be 0. It's also software that's likely going to have to through very expensive certification procedures to be allowed on the roads (or to be allowed by insurance companies). How could it possibly be economical for a manufacturer with 2% market share to do this on their own?

So could a smallish manufacturer at least build a better one, if not cheaper? It's hard to see why you'd expect that. Maybe if 20 of them tried, a couple of them would end up with a better technology than what could be bought. But even if that's true, it's not going to brighten the day of the remaining 18 manufacturers who ended up with substandard software. There's one obvious exception (regional differences - maybe Japanese drivers have very different preferences from German ones, or something).

Are there any integration benefits from making the software for self driving cars in-house? I can't think of any, but I'm not too familiar with the automotive industry. Maybe there's something obvious I'm missing.

Of course there's no guarantee that even if the future ends up as one of a few major in-house systems and a couple of successful publicly available ones, Google's solution would be one of the successful ones. Still seems like it's worth a shot.

<comment><USER27> There are very few standardized systems in the automotive industry, especially for "luxury items". Recently, that's changed with some manufacturers using the same undercarriage to build different cars. It would take a huge change in the mindset of a car manufacturer to buy something like this that could be a competitive advantage.

<comment><USER31> Granted, but given that most of them haven't even been able to get their in- dash software systems right (look at Ford's debacle), how likely are they to be able to make dependable self-driving cars?

</comment></comment></comment></comment></comment><comment><USER32> Does anyone know what languages are used to build the software brains for the car? I haven't found any information on the actual software architecture, more on the hardware.

<comment><USER33> <http://en.wikipedia.org/wiki/DARPA_Grand_Challenge> has a bit on the languages.

</comment></comment><comment><USER34> The technology is impressive, but humans drive okay without LIDAR, radar, or GPS. Maybe some day self-driving cars can drive using only two small visible- light sensors located above and behind the steering wheel. It might just be an AI challenge to operate that way, and commercial systems will always employ advanced sensors for better safety. But I don't think true parity has been reached until they can drive like we do.

<comment><USER35> But people aren't very good at driving, it would be silly to try and handicap computers with the features we evolved. Every new car made already has lots of advanced technology to make up for our two eyes.

<comment><USER36> Agreed, I don't think we should strive for parity. I'd much rather see driverless cars that are better than humans at driving, even if they need more tools to do it. The more poor drivers we can replace with driverless cars, the better.

<comment><USER34> Commercial self-driving cars should use every sensor modality which is cost effective and which improves safety. I would never argue we should hamstring our driverless cars, let's give them the best shot to be uber-safe and reliable, no question.

In the mean time, on a completely non-commercial separate track, AI researchers should try to do more with less. Driving using only visible-light sensors is a challenge. AI is pushed forward by taking on challenges exactly like this, let's see the push continue.

These two tracks may in fact intersect. When your LIDAR and radar are caked with ice and mud, you'll want the car to be able to drive visually at least to a safe stopping point.</comment></comment></comment></comment>


Spectre via AVX Clock Speed Throttle? - <AUTHOR> http://www.numberworld.org/blogs/2018_6_16_avx_spectre/ <comment><USER2> The attack assumes that at the beginning of the attack the CPU is _not_ in AVX clock throttle mode. The code should wait for the CPU in normal (non-throttle) mode before starting the attack.</comment>


Ask HN: Has Intellectual Ventures Gone Dark? - <AUTHOR> A few years ago they were going TED talks, blogging like crazy about saving the world from malaria and creating power from spent nuclear fuel.  And, most notably, earning a reputation for being a no-holds-barred patent troll.<p>So... what's happened to them lately? <comment><USER2> Their fund is way down: [https://www.forbes.com/sites/nathanvardi/2018/06/01/after-10...](https://www.forbes.com/sites/nathanvardi/2018/06/01/after-10-years- nathan-myhrvolds-3-billion-of-private-equity-funds-show-big- losses/#7f2ec3b15a9d)

Their model probably doesn't make sense anymore given how the case law has developed. (Thankfully)

<comment><USER3> >In total Myhrvold's firm has acquired 95,000 patents and launched or been behind dozens of lawsuits, making it a giant patent troll

Man how do they find the time to properly even evaluate those patents?</comment></comment>


Kurt Vonnegut's Slaughterhouse-five and Erlang - <AUTHOR> http://www.readncode.com/podcast/slaughterhouse-five-and-erlang

<comment><USER2> This is a very unlikely combination. Strangely fun though.

</comment><comment><USER3> Great show. Keep it up!</comment>


Imo.im supporting Skype and Introducing Voice, Video Capability On All Networks - <AUTHOR> http://www.honeytechblog.com/imoim-supporting-skype-and-introducing-voice-video-capability-on-all-networks/

<comment><USER2> Interesting that it supports Skype, which is the only protocol in the list that doesn't have third party clients (afaik; if I'm mistaken, please correct me).

That'd mean they either partnered with Skype (which would be a first, so I don't think it's likely), or are using Skype client API and rerouting audio from/to it. That's quite a feat, especially if they can manage that in a scalable (wrt the number of users) manner.</comment>


JDK 11 Early-Access Release Notes - <AUTHOR> http://jdk.java.net/11/release-notes <comment><AUTHOR> JEP 323: Local-Variable Syntax for Lambda Parameters</comment>


Eg: Never forget a command again--now with Color - <AUTHOR> https://github.com/srsudar/eg

<comment><USER2> I've used [https://github.com/chrisallenlane/cheat](https://github.com/chrisallenlane/cheat) for something similar to this as well. Do you know how the work flow differs?

<comment><AUTHOR> That looks great, I hadn't heard of that one. I knew bro did something similar.

Cheat looks similar to eg, but I would argue that eg is prettier, with `man`-style default coloring and the ability to customize the colors to whatever scheme you want. eg includes a more usable explanation rather than pure examples. It also takes a "create your own examples" approach, while cheat seems to take more an "edit your own examples" approach. You can do both with eg, but the general idea is that you would leave the defaults as is.

Still, cheat is a great link. I should probably add a "similar tools" section to the eg readme.</comment></comment>


MIT develops a portable, high-resolution 3D imaging solution - <AUTHOR> http://bostinnovation.com/2011/08/09/mit-develops-a-portable-high-resolution-3d-imaging-solution/

<comment><USER2> I wish HN had a "wow" button. Simply upvoting a submission like this one seems... inadequate.

<comment><USER3> Context: _GelSight can register "physical features less than a micrometer in depth and about two micrometers across," which means it can create a 3D image of ink on a piece of paper (below):_

Below that there is a 3D image of ink on a piece of paper. Taken with a handheld device. "Wow" about covers it, although I might go with "WOW."

</comment></comment><comment><USER4> So has everyone else, apparently. (I'm at Siggraph. (Off topic, I also learned I can't really see glasses-free 3D, but I'm not stereo blind. One eye may be slightly more dominant, so it could be an issue of 'calibration' I suppose.))

MIT's is definitely the coolest and best I've seen though, I don't think I've seen anything like it. Everyone else's is a light-based scanner or algorithms to 3D-ify mostly flat imaging. This amazes me beyond no end.

</comment><comment><USER5> _"When the metallic side is pressed against the surface of an object, the rubber deforms slightly"_

while the concept is great, it still doesn't maximize precision (for high resolution analysis), since the pressure can also deform your object of interest. ideally, you would want to use a metallic as less viscous as possible to keep the surfaces rigid.

</comment><comment><USER6> This is truly remarkable. I woke up in the middle of the night after reading this with a few improvements that can turn this into a human-equivalent level skin sensor for robotics.

Temperature: add something that changes color based on temperature.

Wetness: add some microchannels and watch them as they wick moisture into the material

Pain: introduce small ink packages that will burst if the material is damaged.

Vibration: add a microphone to detect pressure changes in the touched object, or if your cameras are fast enough just watch the surface as it moves up and down.

This could also be simply expanded to senses we don't have: Magnetism (ferrous particles), radiation(scintillation), PH level(litmus), detecting the presence of any chemical directly(specialised receptor), etc... this is revolutionary.

Using cameras behind a gel is a simple, non-obvious(to me), solution to the contact sensing problem. This is going to be used everywhere.

</comment><comment><USER7> I wonder how easy a cheap, low tech version of this would be to make. A camera staring at the underside of a clear gel with an incredibly thin layer of opaque reflective pigment on top of it could pick up and translate a depth map if the surface were evenly lit.

</comment><comment><USER8> The computer vision part might be related to polynomial texture mapping: <http://www.hpl.hp.com/research/ptm/>

</comment><comment><USER9> I don't understand how this works. Little help hn!

</comment><comment><USER10> Inside sources say that it will be called Nitendo 3DS</comment>


True story: Millions still in the bank, GoZoomo shuts shop, returns VC money - <AUTHOR> https://www.techinasia.com/millions-bank-saif-partnersbacked-gozoomo-shuts-shop-heres-happened <comment><USER2> I am not sure what to make of this. Partly yes, returning money is good, but I still feel they did not try hard enough. I see tweets if their website being down a month or so ago as they did not renew the certificate.

Startups are not built with defined market, they are a journey to find product market fit. It feels like they just gave up.

</comment><comment><USER3> Lots to learn from this: biggest one for me is to overcome the greed to use up all the VC money.</comment>


An Interview with the Old Man of Floating-Point (1998) - <AUTHOR> http://www.cs.berkeley.edu/~wkahan/ieee754status/754story.html

<comment><USER2> This short interview is quite inspiring. Here is a choice quote:

"I did not bill Intel for consulting hours spent on those aspects of the i8087 design that were transferred to IEEE p754. I had to be sure, not only in appearance and actuality but above all in my own mind, that I was not acting to further the commercial interest of one company over any other. Rather I was acting to benefit a larger community. I must tell you that members of the committee, for the most part, were about equally altruistic. IBM's Dr. Fred Ris was extremely supportive from the outset even though he knew that no IBM equipment in existence at the time had the slightest hope of conforming to the standard we were advocating. It was remarkable that so many hardware people there, knowing how difficult p754 would be, agreed that it should benefit the community at large. If it encouraged the production of floating-point software and eased the development of reliable software, it would help create a larger market for everyone's hardware. This degree of altruism was so astonishing that MATLAB's creator Dr. Cleve Moler used to advise foreign visitors not to miss the country's two most awesome spectacles: the Grand Canyon, and meetings of IEEE p754."

Also, please read "What every Computer Scientist should know about floating-point arithmetic" available at [https://ece.uwaterloo.ca/~dwharder/NumericalAnalysis/02Numer...](https://ece.uwaterloo.ca/~dwharder/NumericalAnalysis/02Numerics/Double/paper.pdf).

</comment><comment><USER3> It's unfortunate that Intel didn't consult Kahan earlier in the design process of the 8087, when they could have designed a base 10 floating point unit, as recommended by Kahan.

At least for spreadsheets and other accounting software, as well as most uses of JavaScript, IEEE 754-2008 decimal64 arithmetic is more appropriate than IEEE 754-1985 binary64 arithmetic. It astounds me how many professional programmers report bugs that aren't bugs but misunderstandings of binary floating point rounding. Excel has some ugly display hacks to hide some of the binary floating point number quirks from users, but this results in some numbers that display identically but are not equal according to the = operator.

Given the wide birth that programmers give to floating point number comparison and rounding, I wonder what would happen if a browser vendor shipped a dialect of ECMAScript/JavaScript that used decimal64s to implement Numbers. I haven't read the any of the ECMAScript standards in full, but I imagine this would be a non-conforming variation.

<comment><USER4> The only benefit Base10 has over Base2 is that it's more easily understandable by beginners.

It's more complex to implement in hardware. It still has exactly the same precision issues that must be taken into consideration. It still cannot represent everything exactly (1/3 in base 10 decimal. It gets truncated).

Using base2 floating point is pretty much the same as using base2 integers.

<comment><USER3> > The only benefit Base10 has over Base2 is that it's more easily > understandable by beginners.

Dr. William Kahan argues better than I can [1][2]. As far back as the 1970s, he tried to convince both Intel [3] and IBM [2] to implement base 10 floating point in hardware.

First of all, in an ideal world, all software is written and reviewed by people have taken, aced, and remembered their discrete math courses. We don't live in that world. I work with a lot of bright people, but I've come to find that many of them have a model that's essentially floating point operations result in a value that's a low variance Gaussian distribution about the correct value. It's not uncommon for me to see things like doubles compared thusly:

        if (abs( floor(x) - floor(y) ) < 1e-30) ...

Secondly, almost no financial or accounting rules or regulations are drafted by people with any knowledge of binary floating point semantics, so the semantics of IEEE 754-2008 decimal numbers more closely match financial rules and regulations.

Thirdly, base 10 floating point numbers are less confusing for end users and result in fewer hacks such as the display hacks in Excel to prevent users from thinking floating point artifacts are bugs in Excel.[1]

I think IEEE 754-1985 is a wonderful and well thought-out standard. However, the IEEE 754-2008 committee didn't add decimal floating points on a whim. There are very compelling use cases.

      [1] http://www.cs.berkeley.edu/~wkahan/ARITH_17.pdf
      [2] http://grouper.ieee.org/groups/754/email/msg01831.html (search for Yorktown Heights)
      [3] https://en.wikipedia.org/wiki/IEEE_754-1985#History

Edit: It was a bit harsh to begin with "Incorrect." Sorry.

</comment></comment></comment><comment><USER5> Back around 81 or 82 I was a principal in a software that marketed a software implementation if IEEE 754 and associated libraries, developed by Rick James, formerly of CDC, and Bill Gibbons, formerly of HP. It had a small market among compiler writers because no hardware supported it other than the 8087. Even so it was faster than the native 8087, but dont hold my feet to the fire if my memory is faulty. It was a very hairy specification to implement, because it included everything, even the kitchen sink. It was the kind of floating point that an astrophysicist would love. (I had several of those for roommates way back when.) Even by the 90s, I dont think any hardware manufacturer had implemented it in all its glory. If someone told me that no one has done do yet, I would not be surprised.

</comment><comment><USER6> "I think it is nice to have at least one example -- IEEE 754 is one -- where sleaze did not triumph. CDC, Cray and IBM could have weighed in and destroyed the whole thing had they so wished. Perhaps CDC and Cray thought `Microprocessors? Why should we worry?' In the end, all computer systems designers must try to make our things work well for the innumerable ( innumerate ?) programmers upon whom we all depend for the existence of a burgeoning market."

Indeed, we programmers are very lucky that IEEE p754 won and became the ubiquitous standard.

</comment><comment><USER7> I didn't realize that Java implementations did not implement all of IEEE 754, at least at the beginning. [0]

Is this still the case?

[0] [http://www.cs.berkeley.edu/~wkahan/JAVAhurt.pdf](http://www.cs.berkeley.edu/~wkahan/JAVAhurt.pdf)

<comment><USER8> It's still the case. For example, there's no way to set a rounding mode that applies to operations with primitive floats and doubles.

</comment></comment><comment><USER9> Previous submission: [https://news.ycombinator.com/item?id=6656197](https://news.ycombinator.com/item?id=6656197)

</comment><comment><USER10> A few years ago, I had the opportunity to speak with someone who was involved in p754, and he claimed that Kahan took advantage of the fact that Kahan took advantage of the fact that a number of his students were on the committee to add unecessary complexity to the standard.

I offer this anecdote not because I necessarily believe it's true, but because I think it offers more perspective on just how acrimonious the arguments over things like gradual underflow were.

I'm not a CPU designer, and so I can't speak to the merits of the case, but I do note that to this day, a large fraction of embedded CPUs do not have hardware support for denormals, but rely on the OS to implement it in software. My intuition is that this is not due to it being intractible, but rather the FPU being an afterthought on a lot of embedded processors.

</comment><comment><USER11> Does anyone know if the current/recent processors from Intel and AMD still perform relatively slowly in number crunching with denormals and NaNs? I remember it used to be like hitting a brick wall performance-wise if these crept into your data...

<comment><USER12> AMD since long a while wasn't as slow for NANs whereas a few generations ago Intel was certainly 100 times slower as soon as the NANs are there. The first processors that aren't are Sandy Bridge ones, apparently.

<comment><USER13> Inf and NaN have been handled at speed at least as far back as Core (probably on P4 too, but I'm not certain, as I never really worked with those). [edit: I'm referring to SSE/AVX; I forget that there are people who still use x87, where this stall is still around].

Denormal stalls, which are on the order of 100x, started to go away for addition in SNB. (IIRC, AMD doesn't handle denormals at speed either, but I'd need to double-check that).

<comment><USER11> Thanks, yes I was thinking of both x87 and not just vector instructions. Any other info you have would be helpful :)</comment></comment></comment></comment>


Maximum number of characters using keystrokes A, Ctrl+A, Ctrl+C and Ctrl+V - <AUTHOR> http://stackoverflow.com/questions/4606984/maximum-number-of-characters-using-keystrokes-a-ctrla-ctrlc-and-ctrlv

<comment><USER2> Press and hold A, don't let go, prints infinite As with one key stroke.

That's not writing a program and it's probably not the answer Google wanted but software can't really do a "keystroke" anyway, it just prints characters to the screen/file/whatever.</comment>


Kirk: A highly-flexible thread pool - <AUTHOR> https://github.com/kinghajj/kirk <comment><USER2> There is some technical discussion about this on /r/rust: [https://www.reddit.com/r/rust/comments/43ajja/kirk_a_highlyf...](https://www.reddit.com/r/rust/comments/43ajja/kirk_a_highlyflexible_thread_pool/)

</comment><comment><USER3> ..for Rust

<comment><USER4> Yes, it took entirely too much reading to determine this.

<comment><USER5> Hint for anyone not aware: click the coloured bar beneath the 'commits, branches, releases, ...' buttons to see the breakdown of languages in a GitHub project.

(I agree with you that the README could have made it clearer, but clicking that bar is about the second thing I do when I visit a GitHub repo :) ).

<comment><USER6> What's the first thing?

<comment><USER7> Probably read the description. At least for me I do so.</comment></comment></comment></comment></comment>


Scaling MySQL to 700 million inserts per day - <AUTHOR> http://tech.bluesmoon.info/2009/09/scaling-writes-in-mysql.html <comment><USER2> This article was mis-titled: The title should be "how to get poor performance by using a completely inappropriate tool".

Quoth the article: " _Several million records a day need to be written to a table. These records are then read out once at the end of the day, summarised and then very rarely touched again._ "

This isn't a job for a database. This is a job for a _log file_. You might want to use a database to store the summarized data, of course; but bulk data which is written, never updated, and quite likely only ever read once? That's practically the definition of a log file.

<comment><AUTHOR> some hackers hack simply to find out what's on the other side

<comment><USER3> No, it's just another case of RDBMS blinding people for all other possible solutions.

<comment><USER4> Have you ever noticed how when this happens, it's practically always MySQL? (And when people complain about how badly relational databases perform and it turns out they don't know about indexes, transactions, or stored procedures, it's _always_ MySQL...)

<comment><USER5> This.

The non-MySQL RDBMS people that I know, know when their RDBMS of choice isn't the right tool for the job. Most of the MySQL people I know, seem to think that you just shove everything into the DB, and let Eris sort it out.

Because no other member of the pantheon is crazy enough to even look at that mess.

<comment><USER4> I suspect a network effect is in place where the vast majority of people whose entire understating of databases came from "PHP + MySQL For Dummies"-caliber books, blog posts, etc. use MySQL by default. A critical mass of them end up perpetuating bad advice, griping about how since MySQL hasn't worked well for them, all RDBMSs are junk, etc. Then, people looking for advice starting with databases read _their_ tutorials. To some degree, MySQL probably brought this upon themselves[1], but now there's a feedback loop in place[2][3][4].

       [1]: http://www.reddit.com/r/programming/comments/764fp/mysql_vs_postgresql/c05sayb
       [2]: http://sqlanywhere.blogspot.com/2008/03/unpublished-mysql-faq.html
       [3]: http://news.ycombinator.com/item?id=561277
       [4]: http://ask.metafilter.com/117908/Theres-got-to-be-a-faster-way-to-update

There seems to be a similar effect between Linux and BSD. I'm not going to claim that BSD is objectively superior in every regard, but on average, the BSD community seems to be quite a bit better informed than the Linux community. It may just be because Linux is so much more visible. People using BSD, Postgres, etc. probably already knew enough to evaluate their options, while the path of least resistance stays overrun with clueless newbies.

</comment></comment></comment></comment></comment></comment><comment><USER6> I wonder why they used a database at all: "These records are then read out once at the end of the day, summarised and then very rarely touched again."

And later on they end up writing them to a text file and bulk inserting them in 10K batches. Wouldn't it be easier to just write them all to a file then summarize at the end of the day? (It also says they do a DROP TABLE on each day's data.)

</comment><comment><USER7> A couple of points for those thinking about doing something similar:

"Since InnoDB stores the table in the primary key, I decided that rather than use an auto_increment column, I'd cover several columns with the primary key to guarantee uniqueness. This had the added advantage that if the same record was inserted more than once, it would not result in duplicates."

The 'correct' way to deal with this in MySQL is using the auto_increment_increment.

[http://dev.mysql.com/doc/refman/5.0/en/server-system- variabl...](http://dev.mysql.com/doc/refman/5.0/en/server-system- variables.html)

Of course, the real difficulty with mutli-master setups split across data centres isn't ensuring uniqueness of primary keys, it's ensuring data- integrity under a split-brain scenario, i.e. where one server can't reach the other, but users can reach one or the other. UPDATEs and DELETEs to rows can then become extremely difficult to merge back together. This wasn't a problem for this application, but as others have commented, this use case probably wasn't best suited for an RDBMS anyway.

<comment><AUTHOR> with an autoincrement id, duplicate rows may get inserted. having a primary key derived from the data results in duplicate rows getting discarded (this is important).

secondly, the autoincrement id adds 4 bytes to each row which are never used for anything. only use an id if you need to reference a row from another table.

<comment><USER4> That's a good warning sign that the data isn't relational in the first place. An RDBMS would probably be a good fit for the analyzed data (which is likely to have explicit _relations_ ), though.

<comment><USER8> No it's not. There are plenty of tables that use composite keys that also contain foreign keys.

The use of ORMs like active record, many of which choke on natural keys, has turned a lot of devs into automatons for artificial key creation. Natural keys are often superior.

</comment></comment></comment></comment><comment><USER9> Why no discussion of the disk drives supporting this database? The write performance dropped to 150 when the disk starts getting pounded as, up to that point, everything was in a memory buffer. Does the temporal partition spread the file over multiple drives? What's the capacity and theoretical throughput of the drives?

<comment><AUTHOR> RAID 10 7200rpm 6x1TB

</comment></comment><comment><USER10> Interesting use of tables, as previously commented, but we at room.ly surely appreciative of your post as we are currently on a PHP/MySQL diet and looking to reach critical mass soon after a few updates

</comment><comment><USER11> This seems to be at Yahoo!</comment>


Ask HN: Will Google+ cause Google to be banned in the workplace? - <AUTHOR>

Just like Facebook?  No more gmail at work?<p>What dost thou think? Any early reports from the workplace? <comment><USER2> What I suspect will happen is that the major proxies (e.g. WebSense) will block plus.google.com just like they block mail.google.com now. No reason to block all of google - likely, they just haven't gotten around to it yet.

</comment><comment><USER3> Our work already blocks gmail, and they blocked plus.google.com the second it was live, but they don't block google.com.</comment>


PolyForm Noncompete Licenses - <AUTHOR> https://writing.kemitchell.com/2020/05/14/PolyForm-Defensive-Perimenter.html <comment><USER2> The real problem with the licenses is that they are not open source, but many users of them still seem to think they are doing open source.

The funny thing is that they are trying to protect themselves from Amazon and other competition before it usually exists, and that in reality, they are doing themselves more harm because the big co lawyers are starting to reject these unusual, project specific license. "If it takes more than a few minutes to understand, then I tell the devs No"

To all those would be users of the Faux Pas OSS licenses, why did you make it open source in the first place? If you want to protect your code, why no make it private? Why use one of these licenses?

<comment><USER3> I had a conversation with a company a few weeks ago about this. What they told me aligned with other things I've heard. Basically they're seeing customers giving preference to open source software and they believe (rightly or wrongly) that using one of these non-compete licenses will give them the marketing advantages of open source without the potential business model downsides.

Of course, they also likely don't get the development model advantages of open source but anecdotally these companies don't much care about that. (And TBH a lot of single-company products/projects don't get a lot of outside contribution anyway.)

<comment><USER4> Could the company use something like AGPL in these instances? (The developing company ofc wouldn't follow the AGPL, but in this case the code is _officially_ open source.)

<comment><USER3> It's possible. Although a cloud provider could still potentially run a competing service so long as they made any modifications available to the public. (A cloud provider still might choose not to do so because of uncertainly about how the code interacts with other services in their infrastructure.)

But, yes, "Why doesn't the AGPL solve your perceived problem?" is a reasonable question to ask in the context of these non-compete licenses.

</comment></comment></comment></comment><comment><USER5> Let's say I work at Giphy and we publish a library with the Defensive license. Then the library is used by the folks at Twitter. Okay, Twitter isn't competing with us and they send lots of traffic our way, our team is cool with that. Then Giphy is acquired by Facebook. Is Twitter in trouble?

<comment><USER6> Alternative, but similar scenario:

Let's say a database gets licensed under the defensive license by $CORPORATION_0. And let's say that $CORPORATION_1 makes many contributions to that database under the same defensive license (where they retain copyright). A little weird, but presumably both companies are comfortable with the situation.

Let's then say that $MEGA_EVIL_DB_CORP buys out the contributor $CORPORATION_1, and now $MEGA_EVIL_DB_CORP owns the copyright and has competing databases.

I'd assume both companies can no longer use the defensive licensed DB. Meaning all Oracle has to do to destroy the competition is buy whichever company is cheaper.

That seems like a bad attack vector.

<comment><USER7> IANAL but it seems like a non-compete license would need copyright assignment so it's clear who you can't compete with. The dual-licensing bait-and-switch business model also requires copyright assignment so it's not that different.

</comment></comment></comment><comment><USER8> As an open source developer, I wouldn't contribute to any project that uses these licenses or trust any company that's using them. They're not classified as free software or open source for a reason: it's crucial to be able to fork in the event that the company decides to become hostile. The ability for the other contributors to do this is what keeps them honest. With these licenses, that whole trust aspect gets thrown out.

</comment><comment><USER2> Joseph Jacks has some interesting ideas for Commercial Open Source Software (COSS) [https://coss.media](https://coss.media)

Though he recently told me that he thinks all OSS should bootstrap and never take investment, which doesn't exactly align with top COSS co spreadsheet he also maintains.

<comment><USER9> Hey, Tony. :) I believe that COSS companies are extremely successful when they are able to build large and successful positive-sum and inclusive ecosystems around their FOSS core (specifically, that core being FOSS licensed, not source-available license'd). My partner Heather Meeker has written most of these non-compete licenses. They are useful at the crust around the core, not in the core, IMHO.. if they are applied to the core, there is very little distinguishing it from freemium/proprietary which != FOSS. Also, many of the most successful COSS companies never raised a cent of VC to get to scale: Jetbrains, Liferay, Odoo, etc. and the ones that did raise a similar amount of money to get to scale did not really need it, they just accepted it along to way maybe to speed growth a bit, but their commercialization strategies were often working quite well and their customer acquisition costs _highly_ efficient.

<comment><USER2> Hi JJ.

Steph and I have been breaking things down from our chat, and basically came to the same conclusion, though often favoring closed source where one might GPL/NonC license that crust around the core. Also that outside investment is to add fuel to an existing fire, COSS or fully private makes less difference than showing you've built something people want.

Do you have any new videos or podcasts? Always love to hear your thoughts, you put things very succinctly!

</comment></comment></comment><comment><USER10> Let's say a repo on GutHub has the Perimeter license, and I clone it to a public repo. Would I be unable to include any personal changes on the clone I have? Because it'd be a substitute product that's distributed via GitHub?

</comment><comment><USER11> s/complete/compete/

I appreciate attempts to standardize the law, and make it more accessible and cost-effective to rely on.

Hmmm, guess there are issues though

<comment><USER2> The OSS license body is rejecting these non-compete licenses as open source.

<comment><USER3> To be somewhat pedantic, the Open Source Initiative maintains the open source definition and has a license review process which can lead to a license becoming an OSI-approved license. There are a variety of reasons licenses don't get approved but one of them is that it doesn't meet the open source definition.

I'm not sure any of these "non-compete" licenses have been rejected by the OSI. I'm pretty sure at least some of them haven't been submitted because they almost certainly would fail to be approved.

But to be clear, anyone can claim their license is an "open source license" just not that it's an OSI-approved license if it's not.

<comment><USER2> I suppose what I am getting at is that, like with many things, humams tend to gravitate towards adopting definitions around the governing body (experts) certification. We can get into problems, like certified organic, when there are too many bodies creating standards. There was actually an analogous conversation in Cuelang about this, w.r.t. user registered builtins, Cue code which can no longer be used with cue, and the worry of fracturing the ecosystem.

</comment></comment></comment></comment><comment><USER12> Are these enforceable in California? California does not like non-compete clauses.

See cal civ code section 16600: "... every contract by which anyone is restrained from engaging in a lawful profession, trade, or business of any kind is to that extent void"

<comment><USER13> I believe copyright law in the U.S. is governed by federal statute and copyright infringement matters would be handled by a federal court.

<comment><USER12> You might be right about that, but federal courts can consider state laws. I'm not sure how that would play out.

I also found an unpublished opinion from SCO Group, Inc. v. Novell, Inc., that deals with a similar issue that also makes me think that this software license could work:

> The license in the APA and the TLA does not preclude Novell from pursing its > business. Rather, the license merely restricts Novell's ability to use SCO's > property and is part of an ongoing relationship between the parties. > Therefore, the court finds that there is no restraint on trade and the > restrictions are not void under Section 16600.

</comment></comment></comment><comment><USER14> I am not a lawyer, and none of this is legal advice, but these licenses seem SAF (Sketchy As...).

More precisely, using software written with these licenses would be something I would never do, either in an Open Source project or a commercial project.

Consider for example the 'Patent Defense' section of the Polyform Defensive license. If I am reading this right then if you have a patent and use Polyform Defensive licensed software from Example,inc. to the point that stopping using the software is a major hardship, then Example, inc. can infringe on your patent and be safe because you won't risk losing the right to use their software.

Or the 'Sales of Business' section. Let's say Example,inc. is building a blog hosting platform and Open Sources a library for an image carousel under Polyform Defensive. Exemple SA start using it for their Computer Based Training site. Later Example,inc. enters the CBT market. If I am reading this right then Exemple SA now has to either stop using the software, or leave the CBT market - and might not even have a choice about leaving the CBT market.

A lot of work has gone into making useful and effective Open Source licenses that benefit both sides when a company open sources their software (software user and the company making the software). A company has a range of protectiveness they can choose: Affero GPL, GPL v3, BSD, MIT, Apache, EPL are some well known ones [1]. Why do we need the PolyForm licenses, especially when they seem to me to be several steps back toward the dark ages of commercial licenses, and being so ambiguous you need a lawyer to evaluate it every case.

You also have the question of legality in every region. Aren't noncompetes heavily restricted in California.

I also am of the mind that 98% of noncompetes and NDAs are hubris and unnecessary, other than to use as a collar to retain employees. Better to retain through incentivizing than threatening. And also, ideas are a dime a dozen..most people are not going to steal your idea as it's the execution and the funding backing it that will make the difference.

Lastly, a key thing to not is that the Polyform Project itself says these are not Open Source licenses[2]:

      PolyForm is not…
      Open source or free software.  There are plenty of
      existing open source licenses. PolyForm is not a
      substitute for them, but an alternative for those
      who want to license source code under limited rights.

There are Open Source licenses out there that legal experts state will protect you, whatever your range of needs if you are willing to abide by the Open Source ideals[3]. Why not embrace the Open Source movement, instead of saying mired in the past?

[1] [https://en.wikipedia.org/wiki/Comparison_of_free_and_open- so...](https://en.wikipedia.org/wiki/Comparison_of_free_and_open- source_software_licenses)

[2] [https://polyformproject.org/what-is- polyform/](https://polyformproject.org/what-is-polyform/)

[3] [https://opensource.org/licenses/category](https://opensource.org/licenses/category)

<comment><USER15> It seems the most on-topic comment was downvotes into oblivion.</comment></comment>


Ask HN: Rate my Kickstarter project - KOTHpoker - <AUTHOR>

So my team and I have been bootstrapping the development of our site http://kothpoker.com and we decided that Kickstarter would be the best way to raise a small amount of funding. Any advice/comments/concerns are greatly appreciated!<p>Here's the link- http://www.kickstarter.com/projects/kothpoker/king-of-the-hill-poker-kothpoker <comment><AUTHOR> Clickable - [http://www.kickstarter.com/projects/kothpoker/king-of-the- hi...](http://www.kickstarter.com/projects/kothpoker/king-of-the-hill-poker- kothpoker)</comment>


Ask HN: Are you thinking about forming a startup now, or not? - <AUTHOR> & if you're thinking, do you feel pain on finding some early team members? <comment><USER2> Yes, my pilots have been adversely affected by the lock down. I had to postpone my execution by at least 2 months. Also, several people who expressed interest in being our customers have retracted due to diminished demand for their business.</comment>


Show HN: Find places to meet in the middle with your friends - <AUTHOR> http://www.wheretomeetup.com

<comment><USER2> Nice start! What do you think about letting the users adjust the center point? Would be cool to be able to drag and drop the center point on another location. :-)

<comment><AUTHOR> Interesting. I'm not sure if that is technically doable at this point, but I will look into it.

</comment></comment><comment><USER3> Yes, I think this is very useful; what data does it use?

<comment><AUTHOR> It uses yelp for the locations and mapbox for mapping</comment></comment>


NYC sets up quarantine checkpoints as it toughens state travel restrictions - <AUTHOR> https://www.cnbc.com/2020/08/05/new-york-city-sets-up-quarantine-checkpoints-as-it-toughens-state-travel-restrictions.html <comment><USER2> "Travelers who have visited 35 states or territories with high COVID-19 transmission rates are required to complete the state's traveler form as they pass through checkpoints at key entry points into the city."

<comment><AUTHOR> Saw that as well. I can't imagine the logistics and monitoring involved with that in NYC. I guess opting-in to a contact tracing app would do the trick or some type of digital system.

</comment></comment><comment><USER3> Do you think this will ever end? I'm getting kinda fed up with all the different Doctors and so called professional. Seems everyday there is a new doctor on the news.</comment>


The JavaScript Problem - <AUTHOR> https://wiki.haskell.org/The_JavaScript_Problem

<comment><USER2> In a year or two we are hopefully going to see a whole new Javascript (it's already happening now with ES6). For a language that was cobbled together in about a week, it's actually not the massive train-wreck people make it out to be. Sure it might not do things in a pure code way, but you could argue that about languages like PHP as well and at the end of the day it doesn't make them any less usable.

I think Javascript has reached a point where the good developers know of its weaknesses and limitations and thus, they hardly ever encounter them. I can't honestly remember the last time I ran into an issue that was a result of the way Javascript implemented something. In the right hands like anything, Javascript can be a decent language. Combined with something like ESLint and superset like TypeScript, you'll never write bad Javascript again (well it is very unlikely).</comment>


Ask HN: Disqus alternatives - <AUTHOR> zKillboard just turned off disqus comments because of 'hijacking screens' according to the dev, Squizz.<p>What are the alternatives to Disqus? <comment><USER2> This was actually asked 5 days ago :-) Here: [https://news.ycombinator.com/item?id=15511297](https://news.ycombinator.com/item?id=15511297)

I'm developing a new alternative, this year 2017, called EffectiveDiscussions: [https://www.effectivediscussions.org/blog- comments](https://www.effectivediscussions.org/blog-comments) (the website is not ready, there'll be a video + images). Open source, & hosted $2 / month. DEMO: Scroll down to the bottom here: [https://www.kajmagnus.blog/new- embedded-comments](https://www.kajmagnus.blog/new-embedded-comments). There are new ideas — look here: [https://www.effectivediscussions.org/-32/how- hacker-news-can...](https://www.effectivediscussions.org/-32/how-hacker-news- can-be-improved-3-things)

What does "hijacking screens" mean? And what is a killboard :-) I googled for "zKillboard" and Google says "zkillboard.com is a killboard". The website looks like some ranking table for a game?

</comment><comment><USER3> Kayia.com - still in early Beta

<comment><USER2> kayia.com times out. [https://www.kayia.com/](https://www.kayia.com/) works though — but the website says _"A Better Database ... Kayia is relational, like SQL, but accessed via ... like you would with MySQL"_ — this seems like off-topic to me?</comment></comment>


Ask HN: What companies use custom designed server hardware? - <AUTHOR> Most companies use regular cloud providers, like AWS, DigitalOcean, Linode, etc.
However some go above that and build custom server hardware for their use cases.
For example Imgix. http://photos.imgix.com/racking-mac-pros <comment><USER2> Backblaze with their Storage Pods: [https://www.backblaze.com/blog/open- source-data-storage-serv...](https://www.backblaze.com/blog/open-source-data- storage-server/)

Facebook and others via the the Open Compute project: [http://opencompute.org/](http://opencompute.org/)

Google, Microsoft and Amazon, at the very least for deep learning/FPGA stuff, but probably a lot of others as well.

If "just" assembling whiteboxes counts, there is going to be a some of smaller orgs with co-located servers that do this for various reasons.

</comment><comment><USER3> Regarding Google's use of 'custom silicon':

[https://news.ycombinator.com/item?id=13409381](https://news.ycombinator.com/item?id=13409381)</comment>


Contrast: Fail Early, Fail Often, and Learn - <AUTHOR> http://www.contrast.ie/blog/fail-early-fail-often-and-learn/

<comment><USER2> Unfortunately our education system doesn't embrace this philosophy. I've known students who didn't take Calculus in high school because it would hurt their GPA. When we focus too much on initial performance we tend not to take risks and as the pottery example illustrates fail to learn.

</comment><comment><USER3> This blog post is basically an excerpt from "Designing User Experiences" by Bill Buxton.

I have mentioned the book before as one of my faves. Bill Buxton is a brilliant guy and all hackers should check out the book.

<comment><USER4> I loved the message of the book - I only found the first half (a description of the problem) to be useful and eye-opening, however, since the second half where he tries to offer solutions to overengineering or underdesigning products seems a bit haphazard and random.

Definitely worth a read though just to open people's eyes about the problem with most software engineering. I've found this issue at 2 of the 3 startups I've worked at in the last year.

</comment></comment><comment><USER5> For a usability site, it's a really confusing interface, and the text isn't that readable either.

<comment><USER6> Really? I didn't really look at the main site, but the blog portion seemed like... well, a blog. Nothing nonstandard, as far as I could tell. And the font was just blown-up Helvetica, though the letter-spacing did seem a little wide.

<comment><USER5> The spacing hurt readability and I didn't know where to look when I first clicked on the link. Links to old articles seemed to run on together and were the first thing that grabbed my attention, and I had no initial sense of what they were. As I said...confusing.

<comment><USER6> Huh. I suppose that just shows the subjectivity of such things; I found the site to be quite easy to use and well-designed, other than the letter-spacing.</comment></comment></comment></comment>


How to determine which commands failed/succeeded in your Bash_History file? - <AUTHOR> I have a python application I use for taking notes in markdown. It automates several tasks for me and one of those tasks is parsing my command history and logging certain commands to a markdown file.
Parsing out the command and even the timestamp of each command (if your bashrc is setup correctly) in the Bash_History file is easy. However, what if one of these commands was typed wrong or perhaps I forgot a parameter or flag which caused the command to fail. There isn't any bash/zsh environment variable I can set to add this bit of information to the bash_history file like you would for including the timestamp.
How can I effectively and most easily solve this problem?
To be extra clear. Say I have a bash_history file with the following commands. How can I distinguish between failed/succeeded commands?
---Bash_History File---
lsla
ls -la
cdd
cd
---END OF FILE---
For simplicity, lets say I want to parse this file and log all these commands that succeeded but ignore the commands that failed which are <lsla> and <cdd>. Obviously <lsla> is wrong as it's missing the space and '-' character. The <cdd> is wrong cause (for sake of argument) lets say I fat fingered this command. That leaves two commands that succeeded. For a Bash_History file of 5,000 commands this becomes more complicated as each command could have several ways it could look (such as different params and options). So a lookup "dictionary" type of method wouldn't work here.
Therefore, how can I easily determine which commands succeeded and which failed?
What method would best work across both bash/zsh?
Are there environment variables I have to set? For example, to see the timestamp of each command I set the following variable in my bashrc
HISTTIMEFORMAT="%d/%m/%y %T "
Do I need to write my own bash_history program for this? Would like to avoid that. <comment><USER2> > Do I need to write my own bash_history program for this? Would like to avoid > that.

I didn't even know about HISTTIMEFORMAT, but seeing as how it puts the time in a "comment", which I didn't even know was possible for these readline history files, maybe there's some bash hook you can define that will have access to the return code of each command run and append that to the history file with a comment character on your own. This working depends on having configured bash so that it writes to the history file incrementally (as soon as each command is run and not until you exit bash).

If that fails, in your shoes, I would look into patching bash. I don't think you'll find explicit support for what you want (you've already looked in the documentation, right?), but I'd be happy to be proven wrong.

</comment><comment><USER3> You may be interested in this HN comment from roughly a year ago, in which a user created a playful bash prompt script that displays the number of successful commands run in a row: [https://news.ycombinator.com/item?id=15563117](https://news.ycombinator.com/item?id=15563117). Sample prompt:

      [0] /home/bar/g3 14:19 $ echo "boo"
      boo

      [1] /home/bar/g3 14:19 $

With this as an example ($LAST_STATUS in particular) it seems like writing a custom bash_history program would be very possible.</comment>