skysight-inc/HackerNews huggingface dataset:
A typical mutex has essentially two very different costs depending on whether the lock is already taken by another thread:

- Uncontended case + mutex: no syscall, fast path is basically the cost of the memory barrier.

- Uncontended case + spinlock: no syscall, fast path is basically the cost of the memory barrier. Essentially same cost than a mutex, sometimes a tiny bit cheaper but _if your lock isn't contented in the first place it will be very hard to measure, since not being a bottleneck_.

- Contended case + mutex: thread is waiting in the mutex list without taking CPU. Hyper-threading may also give hand immediately to another thread, perhaps lucky enough to run. The OS mutex may have a bit of capped spinning before waiting in the scheduler.

- Contended case + spinlock: Anything goes. CPU gets consumed just for spinning. Wrong thread might get priority. If you are lucky you did put a HLT instruction to mitigate the complete disaster that spinlocks are, perhaps it even does something. Your consolation: no syscall or thread pausing... because they are spinning.

tl;dr: spinlock are worse in the contended case and essentially the same performance in the uncontended case against your typical OS mutex. SPINLOCKS WON'T YIELD THE EXPECTED BENEFITS, USE REGULAR OS MUTEXES.
The Data Fog of Observability
As I have created similar service (EU based) I wish you good luck with it. Is there a way to track your progress? Do you share your findings anywhere?

I hope you are aware that competition in quite serious in the market. E.g. mypostcard in 2016 claimed that they print 10000 postcards per day. What's your plan about that?
Drifting is awesome.
Great advice, just not for everyone though. I personally agree.
>Also, I will throw in my consiracy theory that most ML researchers and such push the theory/deep stats requirement as a form of gatekeeping.

Learning the fundamentals of a field is supposed to be gatekeeping. It's what stops you from making stupid mistakes. The field of ML is littered with horrible errors made by people who don't know the fundamentals.

Please don't follow this terrible advice.
I know this is supposed to be good news and we should feel good about this, but as a generally healthy person all my life reading this I'm just shocked by the horrible diseases and illnesses that happen to good people just trying to live their lives. Through no fault of their own people end up with pain or disease and their quality of life, their hopes, their dreams, their daily life is affected. There's not a lot I can do to help any one dealing with pain and illness, but I want the best things for those of you who are. It's not your fault, and it doesn't matter if it is, nobody deserves a life of pain and suffering and other bullshit. We need to do the best we can for those affected, including making sure everyone has access to quality medical care.
I don't see how you could possibly overdose on kratom - large doses make you sick (and when I say "large dose", I mean relative to a typical dose of 3-10g - which is nowhere near to an overdose). I don't have a source (on mobile), but I seem to recall reading that you'd need to eat something like a kg if kratom to overdose.

Both cannabis and kratom can be psychologically addictive, in the same way as anything "rewarding" can be.

As kratom contains opioids, it might also cause physical dependence. I say might, as mitragynine is not a typical opioid, in that it doesn't recruit beta-arresting - which is thought to be responsible for the build up of tolerance and dependence by opioids, as well as for some of the negative side effects, such as respiratory depression.

There are many conflicting anecdotal reports claiming that kratom does cause withdrawal on abstinence, or does not. Personally, I have previously been able to stop kratom multiple times with no withdrawal at all (which has certainly not been the case with my prescribed opioid meds). My guess is there may be genetic factors at play here, and of course as a natural product there are bound to be variations in chemical composition of kratom from different sources.
And critical embedded OSes running on IoT devices, but who cares about that. /s
I assume you mean SUVs, not the cargo-carrying semi trailers.

Banning "trucks" is like banning assault rifles: you instantly get into a huge debate about what is and isn't an truck. Is it to be be size? Weight? (Teslas are heavy) Passenger capacity? Whatever definition you use, the results will not be what you want.

It's like when london allowed electric vehicles to skip paying the congestion charge. They thought this was going to benefit the drivers of small electric cars. Then came all the electric sports/super cars. Now Jeremy Clarkson in his 200mph electric hypercar doesn't pay the tax while James May in a tiny fiat panda does.
Postgres also has this feature (via file_fwd)
“Scientists start out doing work that's perfect, in the sense that they're just trying to reproduce work someone else has already done for them. Eventually, they get to the point where they can do original work. Whereas hackers, from the start, are doing original work; it's just very bad. So hackers start original, and get good, and scientists start good, and get original.” - Paul Graham in Hackers and Painters

Which, well, I use as an opening quote to my intro to deep learning, https://github.com/stared/thinking-in-tensors-writing-in-pyt....

BTW: While information theory is everywhere, I have to yet see where measure theory makes a practical impact on practical deep learning. The importance of pure math for practical machine learning is highly overrated (and I speak as someone who did study that).
One more anecdote but a family member's company was put out of business due to the trade war.. small shop, only a handful of employees sourcing factories in China (and Honduras / Italy / Vietnam) for much larger US companies to produce goods for sale worldwide. Think when a large US Firm wants to start producing furniture or fixtures from speciality materials (brass, sustainably sourced mahogany, etc), someone has to be on the ground vetting techniques and doing QA. Sourcing in China had grown to be >50% of their business.

It's the type of thing that won't make the news but certainly devastating to a group of hard working people. My family member had carved out a decent little niche as a manufacturing specialist after the globalization wave off-shored all production at the furniture company they had previously worked for.
I've been using Vim and vim-derivatives almost exclusively for the past 15 years, and I think none of the things you mentioned are important to use vim.

The first and most important things to understand are:

- Normal mode is the default mode. Only leave it when you already know what you want to write.

- Movement follows the [<count>] <verb> <target> model. The most used verbs are: d, y, p

The most used targets are j, k, f, F, /, w, W, e, b

Other useful keys to know and use: a, A, o, O, *, ., %

And lastly, learn how to use macros! (q, @)

If you just learn everything I listed here (and it isn't much), until it feels natural, you already know 90% of what you need to boost your editing speed and use vim like a pro.
Not GP and nothing to do with them, but I have an example of a CSV format which yields absurdly long lines.

We have a CSV for timeseries data, where for some reason someone decided to force each line to represent one data point. However, for some cases, one data point may contain around 30 different statistics for 4 million different IPs, which get represented as 120 million columns in the CSV (think a CSV header like 'timestamp,10.0.0.1—Throughput,10.0.0.1-DroppedBytes,[...],10.215.188.251-Throughput,[...]'). With large numbers represented as text in a CSV, this can sometimes reach more than one 1GB per line.
hi friends
where is the wyze data ???
I have one of those

They’re pretty decent. Solid range. The setup is sorta ok. Requires a bit of googling and tweaking
My Decade in Review
Most of these will be defunct a few years from now, they run on VC money. Becoming profitable in biotech is much harder than IT.
Yes python is more preferred when choosing a scripting language and javascript is more executed in browsers. And the two do not contradict.
Which is why most countries have a system that shows you what they think, and you can accept or not. It’s not like the majority of people are in such a situation, and likely over time that will become less common as its often a byproduct of legacy systems / mergers that lose the original transaction.
You can skip the leap year info completely if you consider both January and February as belonging to the previous year. That makes sense as the additional day (Feb 29) is at the end of Februry.

Last year Pi Day was Thursday, this year Saturday.

So the general rule then is: March 14th, April 4th, May 9th, June 6th, July 11th, August 8th, September 5th, October 10th, November 7th, December 12th, January 2nd, February 6th are Pi Days.

Edit: another nice rule is that usually Pi-Days increase by 1 each year (2 in leap years), so next year it will be Sunday, then Monday, Tuesday, Thursday (leap year), Friday, etc.
> This is the best of both worlds: prototypes are easier for the language implementer to code and classes are easier for the user to use.

Of course you also get the worst of both worlds: the performances of prototypes and the split world of classes.
Just to be clear: the article and analysis are interesting.

The presentation detracts massively from them.
Pthread_mutex on linux is also an adaptive mutex, although the spinning count might not be optimal.
What did people expect? Unless you have an antenna literally pointing in every window of your apartment, reliable 5G ends at the first external wall. It is borderline line-of-sight. Middle of Time Square? Sure. Inside a stadium watching the Olympics? It will work there too. In the parking structure under that stadium? No.
> multiplayer

before you venture there I suggest you move the control code outside of the physic code, abstracting car inputs into a throttle, brake, steer structure which is piloted by inputs elsewhere and feed into the physic update tick along with the car state, or it'll make exceptionally hard to build input prediction and lag compensation further on
( 5 Steps)Exporting Leads from Any Landing Page to Google Sheets with Just
A js lambda to graphs parser and reducer
https://mbuliga.github.io/quinegraphs/lambda2mol.html
We have that. Next?
Among the several puzzling assumptions in the article seems to be the idea that initial planning is the only story worth telling.

It insists all those cities are "razor blades that cut up life," but the streets don't seem to be running with blood.

One way to signal that you have carefully thought through your arguments is a commitment to clarity. If you have nothing up your sleeves, you lay out your points as simply as possible.

Here, poetic hyperboles hide weak leaps throughout the piece. Such tactics are key when the underlying ideas aren't very strong. At worst, they come off as an argument for an irrational phobia of all new communities.

Did no one in Brasilia ever read a newspaper? Really? Is that really the core problem there? Or are we using that silly example to avoid carefully engaging with what actually worked and failed there? Even the categorizations seem arbitrary and collapse on a closer look. Is NYC planned or unplanned? Completely depends on which aspects you're looking at.

I feel like the central argumentative strategy here is a slight of hand. If we take an abstraction, then discuss the examples we abstracted out, it will appear like the abstraction misses some core aspects of reality and is therefore harmful.

That's the entire purpose of an abstraction though!

Of course a city isn't a tree. A city isn't a series of roads either. And yet maps still somehow manage to be useful.

The piece is full of such sloppy argumentation and hyperbolic language it should be used as an example for students of how not to write.
Aww I wrote the Python docx module years ago when I first got into programming as a sysadmin (I was doing lots of xml munging so knew lxml pretty well at the time). Nice to see it included in a guide like this.
Show HN: Low-overhead logging for Java applications
“Lost decade” relative to previous growth. Relative yo the rest of the world they were and still are far ahead.
I think, similarly, that there is an underground graphical rewriting formalism for all of mathematics, category theory included. Category theory is somehow a step towards it, but we don't keep categories in our heads, only the graph reducer.
I think you're both correct. For sysadmin definition of scripting, python would be most popular. For the 'fast to write' definition of scripting then sure, JavaScript.
What you are referring to is mmWave part of the 5G. Which is what media hyped about. Reality is 5G is many things, and it will improve once there are more mobile phone supporting it.

On one hand I think most of the public are far too hyped with 5G. On the other hand you have people who dont fully understand 5G saying 5G is absolutely useless.

Sometimes I wonder how should one report these sort of news, if you go into too much details most people dont want to understand, but if you mention all the pros without the cons you will left reader not fully informed.
I spend most of the day in front of an LG ultra wide and a vertical Kogan 2k connected to an Early 2015 Retina Mac Book Pro and driven using a Magic Keyboard and Magic Trackpad. As far as keyboard and trackpad I love it. Another not so obvious benefit is that I can use my left hand to operate the track pad and it doesn’t feel weird (I’m right-handed).
Teslasuit's New VR-Powered Glove Lets You Feel Physical Objects in VR
you say “created by an amateur” like it’s an insult.

some of the best things we have are created by total amateurs. thats how this works.

i’m not 100% on the life histories of Matz and Guido but wasnt Guido kind of also an amateur too?
> Lithium-ion batteries are notorious for developing internal electrical shorts that can ignite a battery’s liquid electrolytes, leading to explosions and fires.

That seems a little like scaremongering to me bearing in mind the number of batteries that are now deployed.

The use of the word notorious seems a bit over the top.
> And critical embedded OSes running on IoT devices, but who cares about that.

are there current non-homegrown RTOSes that do not reclaim memory ? I know that QNX does.
I agree with your pointa. A note though, I also used to think exceptions are "essential", but after working with code that forbids exceptions and uses explicit error status passing, I find exceptions very awkward to work with. I find them a very lazy way of doing error propagation, which in turn encourages lazy error handling.
Thanks for the link to Kipf's paper, I was not aware of it. I'm a mathematician working on graph rewrite systems, I would like to explore in the NN direction, in case you're interested contact me.
1nm is about 1/60th of a degree of any great circle on the earths surface

(Earth isn’t a sphere so it’s not exact, but it’s pretty close)
If they find anything that works it will be heavily regulated and too expensive for everyday Joe. Modern medicine is all about power, suffering and money.
"This only holds true for brownies and other food-based edibles where you don't know the concentration..."

I've upvoted both of your comments. Since a lot of people won't draw the distinction between the different types of edibles, the previous warning is warranted.
Remembers me the Isle of Tune, part of the forgotten flash based past of the Internet.

https://isleoftune.com/

Edit: Seems like there's an app for that.
you dont have to be proud of it or approve of it to recognize that this is a real thing people do. it helps you realize when it’s being done to you.
Nope, trade deficit is capital outflow. US spends dollars (or gold reserves) to buy goods that are mostly consumed.
I've been experimenting with this idea too. The idea is to drive a fan, which blows on metal heatsink attached on the cool side of the TEC. The air stream further accelerates the fire, so this becomes a reinforcing circle. Directly wiring it is not enough, you need a battery to start, buffer, then you need a controllers, never had time for this

There is a company making beautiful camping stoves with TECs and fans: www.bioliteenergy.com
> blanket ban on all Chinese citizens from working at any research laboratories.

... all mainland China's citizens working at any government-funded research labs, yes.

> I really can't comprehend why we are actively strengthening our biggest economic competitor who play by NO RULES and are a truly evil regime.

I have never been able to figure that out either. If all foreign governments played by rules, maybe it'd make some sense (because the institution or company retains the IP), but mainland China's government never has.

> These Chinese scientists are and will only ever loyal to the CCP.

It's not that bad - not all are and many dislike the CCP. The problem is the CCP can order about and blackmail all who have anything or anyone in mainland China.
I spent more time than I care to admit zooming around on this page
a quick google shows this quote is about advertising, not writing

https://www.google.com/search?q=if+you+don%E2%80%99t+write+i...

(you got me excited so i went to look up source)
I agree 100% with this essay. I’ve been transcribing music manually for just over 20 years, and I’ve dabbled with automatic transcription products and algorithms. A few months ago, I attended my first ISMIR conference (the mostly academic community of researchers working on these problems).

With that background, I’ve come to believe automatic transcription is still so far from good that we’re better off creating tools that make it easier for humans to transcribe. That’s our philosophy behind Soundslice (https://www.soundslice.com/transcribe/), which combines a music notation editor with transcription tools. For anybody interested in transcribing music, I encourage you to give it a try.
I just finished reading Edward Snowden's Permanent Record. I'm really impressed. So much of the first part about his youth had parallels to my own. The writing was clear and honest, and he really hits home how the US, or rather the "West", has changed.

It also made me curious to read Ellsberg–his "Limits of knowledge" chapter is a marvellous read.
Although it's not mentioned in the article, I quite like the term 'kill-free meat'[0], since it succinctly highlights the fact that live animal farming is required for historic meat products (leading to cruelty and environmental impacts).

Also from a 'word security' point of view it'd be tricky for entrenched historic meat producers to wriggle into that category without genuinely changing their practices.

It may not be completely 'comforting' as a term for consumers, but I think if the pricing of equivalent items were similar, it would be difficult to argue for non-kill-free meat during dinner table discussions, and it certainly highlights the difference in a way that any member of the family regardless of age or opinions can understand.

[0] - https://christian-watson.com/kill-free-meat/
I’d love to work on automatic transcription for drum set. I trained in classical percussion, but I’m self-taught when it comes to rock, so I have trouble figuring out how to reproduce fills that I want to play.

I remember using Transcribe!, created by the author of this article, to try to figure out some of the fills in ZZ Top’s La Grange, which isn’t a complicated song exactly, but I can’t figure out how to make the fills feel right. Transcribe! Is great, btw.

Anyways, I’d be very curious to hear if there’s any existing work in this area. I feel like drum transcription could be easier in some ways than “pitched” instruments, but possibly harder in some unique ways too.
"Proponents of legalization should be arguing . . ."

. . . in a way that convinces me, not other people.

That's not how changing minds works.
Things to Know About California Consumer Privacy Act (CCPA) in 2020
More importantly, your links have the full content. The article linked in the title is missing some diagrams, and others are way too small. Thanks!
The money will come from a 10% Value Added Tax (VAT). No new money will be printed to pay for the Freedom Dividend so there will be no inflation.
Thanks for the response! Sounds interesting. I’ll have to look more into it. I love the idea of building software as a charity
"That tempers all associated concerns."

Until you compare the number of sufferers as a percentage of users, there is no tempering of concerns here.
Mystery of Dyatlov Pass
Having a 85kWh battery in your garage would be very useful in areas that are prone to power outages.
Good luck! The market tends to crash right after everyone is exuberant and claiming that it'll go up forever. Then, the adults come into the room, and pull the rug from under them. Then these same people start seeing red and cry that the world is going to fall apart. They completely forget that their previous stance was that the market would go up forever.

On a side note, some people think that they could've timed the Big Short of 2008. If only they had bought a Put. Or go naked, and short the SPY stock directly.

But from my analysis, this was an impossibility. At least to a normal trader. There were just too many fake-outs, too many dead-cat bounces, that the likelihood of you fulfilling your original trading thesis, is nil. The whole thing took place over a 12 month span, which is far too long to execute a derivative trade. So, you would have to short the stock naked, and hold it for 12 months, and hope and pray that your thesis was correct. But, you can only borrow so much money, thus the benefit of such a trade, was not worth the risk. If you made any money, then it would be a rounding error.

Now, if you had insider information (especially on when critical actions were being taken by the government and key players), and if you have significant financial resources, then that might be a different game. And you would've benefited significantly from that once-in-a-lifetime trade. But for the rest of us normal folks, shorting the market in 2008 was impossible.

Anyways, good luck! This market needs to correct. The bigger they are, the harder they fall.

This QE insanity has impoverished us all. Except for the rich elites. They're like vampires that suck on the souls of the poor unwashed masses, and the middle class that hopes to be rich like them but never will, and laugh at us all, as they lounge around on their 3rd yacht.
Palau is first country to ban 'reef toxic' sun cream
I tried switching to a flip phone for a few months. It was an interesting experience but I wouldn't recommend it.

As another person mentioned, fix the problem with yourself, don't blame the technology.

Any benefits you gain from fewer distractions is outweighed by how much harder everyday life becomes.
Yeah, not really going for readable. Just an exercise in eliminating the conditional.
CCXT alternative for working with Real-Time crypto markets tick data
I remember using the instruction-cache as a way to catch debuggers single-stepping through my code. If you rewrote a near instruction to be a jump-to-self single-steppers would fall victim to it..
Instead of targeting end users you can target intermediates like tourist shops. Where the tourist picks a photo from his/hear camera/phone via bluetooth. Or a photo from a touch screen. So instead of buying a postcard, a stamp, writing a message, and then finding a post box, you just have to go to the service in the hotel lobby. Imagine if you are going to send five post cards, you would probably save one hour of work. And the postcards could be guaranteed to come in time due to magic (they are not actually sent from the same country. That part is faked)