skysight-inc/HackerNews huggingface dataset:
> Python threads are basically "green threads"

That's not accurate.

> they have their place but aren't related to parallelisation

You can parallelize all sorts of things with Python threads--just not some things you'd expect to be able to parallelize, due to the GIL. Waiting on or buffering I/O, calling out to compiled code, doing cryptographic operations--all of those can be parallelized, as (in many cases) they entail releasing the GIL.

> But true multiprocessing is ugly when you have hundreds of cores

Why?

> There is no standard UI convention on most OSes to group those processes per app, in terms of signals or stats or whatever.

I have no idea what this means. What do UIs have to do with process groups? Do you know how many processes your Chrome instance is running on the operating system? There are very solid conventions regarding process management, at least on Unix-ish systems: process groups and parent-child relationships are well established and well understood, as is their relationship with signals and signal handling.
The company that I recently joined uses honeycomb.io, versus ELK at my previous job. Maybe I haven't played with it enough, or maybe we have it badly configured, but I find it a huge step backwards. As far as I know, there's no full text search and the types of reports and aggregation you can do are extremely primitive. The UI is also barely usable..huge horizontal scrolling, can't click on a specific value to apply that sub-filter. The list goes on and on. I wish devops team would focus on these fundamentals (proper centralized logging) before playing with all the "cool" and trendy toys.

As for logging, Our `log_format` directive looks like:

log_format stats '$time_iso8601\t$host\t$request_method\t$request_uri\t$request_length\t$status\t$upstream_cache_status\t$bytes_sent\t$request_time\t$upstream_response_time\t$upstream_http_x_route\t$client_id';

This captures most of the generic data you'd associate with a request (time, host, method, uri, length) as well as the generic response data you'd care about (status, length, time to reply). Note that `$request_time` measures the full time to first byte until time to last byte that nginx spends serving the request, vs $upstream_response_time which is more specific to the upstream's response time.

If you're using nginx as a cache, $upstream_cache_status tells you the cache hit/miss status.

A list of all variables is available at http://nginx.org/en/docs/varindex.html

All of our services can set an "x-route" header, which helps canonicalize URIs into something more meaningful. It's up the the service to decide what to do..but /v1/users/ID could be called "users:show". A more complex route might use a different name based on arguments. For example, depending on the parameters we expect some hits to /v1/reports to be very fast, and some to be very slow, so we'll set the name to "reports:list:fast" or "reports:list:slow" so that we can get more accurate statistics.

Finally, we use OpenRestry to do some initial global authentication (along with some other stuff). This is where $client_id comes from. All requests go through something like:

location / {
set $client_id ''
set $upstream ''
access_by_lua_block {
require('execute')()
}
proxy_pass http://$upstream;
}

A piece of that execute code will possibly set $client_id to something which will then get logged.
Okay, I'm not a physician, but for me as a layman there does not seem to be anything new in the study described. Yes, not taking it without indication has always been the professional recommendation. Stopping Aspirin treatment can also increase the risk of a stroke, so the treatment shouldn't be stopped without medical supervision.

I'm wondering whether there is any example of a medicament or artificial supplement that is recommended to be taken without indication. I've never heard of something like that. Vitamin supplements should be replaced by more healthy nutrition and maybe more fresh air, more sun, and doing some sport. If there is no diagnosed deficiency, then supplements have no benefits at all. Most of the "daily supplements" you can buy in a pharmacy can be replaced by occasionally drinking a glass of orange juice, eating a banana, or eating something with honey. I once went to the pharmacy when I had a cold and didn't check what they were giving to me very carefully. At home, I realized that I just bought some pills that contained traces of honey... at a price of 16 EUR!
> Prosperity is not a zero-sum game

But in many cases it's close to it. A company that reduces its expenses by 5% will eventually bankrupt its competitor that wasn't able to do so (all else being equal). A 5% contribution to efficiency allows it to take over 100% of another company's market. The success of a company is in a very large part determined by its competition - more competition means starting a new company is harder.
You gotta play xcom:ew long war mod. It's amazingly deep and different (and difficult). But the game play is a lot more intense and engaging.
The second part of the story, "As Thousands of Taxi Drivers Were Trapped in Loans, Top Officials Counted the Money", is online [0].

[0] https://www.nytimes.com/2019/05/19/nyregion/taxi-medallions....
Yeah, it really does seem like a fundamental difference in how AMD and Intel designed their processors. Researchers have found Intel processors allowing speculation to bypass hardware protection all over the place, and they just haven't found an AMD equivalent. Not only that, AMD have looked into this themselves and released an entire whitepaper explaining why this isn't possible: https://www.amd.com/system/files/documents/security-whitepap... (With, interestingly, one exception. Apparently AMD CPUs allow speculative execution to ignore x86 segmentation. It's just that no-one cares because that's not used anymore. I'm not sure there have even been any mainstream OSes that used that for process isolation.)

This is particularly bad for Intel because most of the SMT-based exploits can pretty much only be mitigated by disabling SMT entirely and taking such a substantial performance hit that they've been trying desperately to convince people not to.
If you believe the calculation to be incorrect you owe it to yourself to identify the error. It should take much less time for you to do that than it took me to compile and reference the calculation for _you_.

The IPCC has compiled known options for getting CO2 down, including aforestation. Its not revealing to focus on the relative rate of change - we increased CO2 at an unprecedented rate, if you would read the IPCC reports or articles concerning the subject with a basic level of regard, you could learn it is in fact possible to also decrease at an unprecedented rate.
Someone else mentioned it, but just to reiterate - these aren't transactions on the blockchain, they're trades on an exchange. They happen essentially instantly, because all that's happening is the exchange is updating its internal customer account balances. The only time this hits the blockchain is when someone withdraws Bitcoin from the exchange.
Love it! This looks like it solves a problem I have for an community project (parsing a 2mb convoluted json with status data for 100+ devices) in an elegant way!

What skills does one need to have to be able to write such libraries for yourself? I'm just feeling like a mediocre copy&understand&adapt&paste programmer but rarely I'm able to create unique concepts/software.
See Syobon Action it's source code as bad as the game itself.

https://github.com/angelXwind/OpenSyobonAction/blob/master/m...
This is why I use Aurelia. It's a Javascript framework many here have probably never heard of or used, it debuted in 2015 and I have been working with it for four years now. Sadly Aurelia debuted at the height of the React hype and soon after, Vue hype.

Rob Eisenberg (the man in charge of the Aurelia project) had the right idea straight out of the gate. A reactive binding and observation system that worked like a virtual DOM (isolated specific non-destructive DOM operations) without the need for an actual virtual DOM. Which allows you to use any third-party library without worrying about compatibility or timing issues with the UI.

This is one area where React falters, at least when I used it. third party libraries clashed with the virtual DOM. When you start introducing abstractions to solve imaginary problems caused by improperly written code (the myth of the DOM being slow) you introduce issues you have to battle later on as your application scales.
Because no one cares to report anything else.

How is it unique in its bloodiness? You are rendering the human history a lovely picture of peace and kind. It may not be as nice as the Chinese government portrait it, and it may not be as bad as europeans portrait it either. There is nothing wrong with leaving it to the past and move one.
Not for me. Get a message that they don’t support private tab.
I’m up for helping, I have a load of ideas in this area...
Wow that's bad. With the mitigations + HT off were looking at more than 40% performance penalty for the average benchmark based on their stats
What's the original recipe and when did it change?
ahah loved it, the frontpage two column and background theme really connected with me, having wrote my first website for grandpa in the 97

this made me wonder tho, 2015+ design are all specialized for sparse information and selling something. what would a modern content heavy site focused not on monetizing would look like today (say, a modern wikipedia of sort for timeless pieces)

said site was brought to 2010 levels of design but got stuck there due how the modern template are not suited for such things
> If OpenAI achieves AGI and you invested in it, you get infinite returns

The article states that this is explicitly false. By design, OpenAI's investor returns are capped at 100x.

I find it odd that 3 other people have also replied to your comment and I'm the first one to mention that OpenAI has explicitly capped investor returns to prevent an explosion in inequality. I wonder how many people read the full article before commenting.
> It makes absolutely no sense to have escaped unicode characters as actual unicode string.

Absolutely no sense? So is a basic Python expression evaluator like this complete nonsense to you?
#!/usr/bin/env python3

try: # Python 2
from Tkinter import Tk, Entry, END
import tkMessageBox as messagebox
except ImportError: # Python 3
from tkinter import Tk, Entry, END, messagebox

import ast
def my_eval(s):
# assume I've implemented this functionality manually...
return ast.literal_eval(s)

root = Tk()
e = Entry(root)
e.insert(END, '"Hell\\xc3\\xb6"') # Assume the user typed has typed in a Python expression, not me
e.pack()
root.bind('<Return>', lambda evt: messagebox.showinfo("Result", repr(my_eval(e.get()))))
root.mainloop()

I get an escaped string... because that's quite literally what Entry.get() gives me from the text box the user typed into. The simple fact that I got a string containing Python source code with escape characters makes "absolutely no sense" to you?

Note that that wasn't even my choice! That was the choice of the built-in Python GUI toolkit... distributed by the same folks who decided this string/bytes overhaul was a brilliant idea...
The fact that Blizzard is rereleasing Classic Wow this Summer should be a strong indicator of where modern games stand, even if it's in the MMORPG genre.
As others have mentioned, as I grow older I play less games. However, I recently purchased an adventure games bundle [0] for the iPad and I've been playing for a couple of hours every night for the past few weeks. There's no IAP or ads in those games, just good old one time payment for content thing. I have nothing against playing mobile games, unless it's the cancerous ads plus ridiculous IAP business model.

[0] https://itunes.apple.com/us/app-bundle/dark-futures-bundle/i...
The Two Questions: Needs and Motivations Affecting Running Health and Success
AFAIK that's just because an Aspergers diagnosis requires an IQ>70.
Pascal's wager is actually logically flawed.

If there are two separate AGI invented, and you could only have chosen to invest in one, then where's the infinite capture of value?

See this video on a reasonable argument about this: https://youtu.be/JRuNA2eK7w0
> you rarely have massively I/O bound things in Python.

Citation needed.
UTMB is probably the most famous Ultra, if you win you will get sponsorship, huge exposure etc. Check the finisher times.

https://en.m.wikipedia.org/wiki/Ultra-Trail_du_Mont-Blanc

Spoiler. It is not even remotely close.
>more sun

Pls no. Skin cancer is no joke.
Uncle Bob about 737 Max 8 crash
Once-Pristine Canyon in Iceland Closed After Bieber Video
> 2. Have almost too much self-belief

Okay. He then goes on to illustrate what he means by it:

> [Elon Musk] talked in detail about manufacturing every part of the rocket, but the thing that sticks in memory was the look of absolute certainty on his face when he talked about sending large rockets to Mars.

That kind of certainty is not self-belief. I think the intuitive feeling that your idea is going to work has nothing or very little to do with the general belief in self. Intuition is usually a result of a lot of computation in the subconsciousness that's delivered in the form of a feeling. The longer you think about something that your subconscious approves, the greater your confidence will be on the conscious level.

But that is pretty rare. Most of the time you play with ideas in your mind, that yield various degrees of this intuitive confidence: from none to "Okay, maybe worth a try" to "Oh wow, I am going to do this before anyone else!". Again, it's all about computation.

The general self-belief, on the other hand, is irrational, stupid and dangerous too. I'd say maybe people with pathological self-esteem problems might need some dose of general self-belief, but normally it should not be used as a driving or defining factor of what entrepreneurship is.
> care more about getting "through" the lecture rather than "getting it"

What's the point in attending if you don't intend to learn?

Perhaps I was simply lucky to go to a good uni or perhaps the times have changed but such lecturers were rare when and where I studied (Exeter Uni., '74-'77) and in the worst cases we campaigned to get them removed from the course.
Why not both? Why not cure cancer and also ask for payment for doing so?
> Pulling or cutting the pensions of retired public service workers (many of whom who risked their lives to protect the public) would, beyond the ethical questions, eliminate the credibility of the city's promises

Well, yes. It would be a default. But more money has been spent than is there and there are only three pools to draw from: taxpayers, services and creditors. (Creditors include both pensioners and bond holders.) At this point, multiple pools have to be hosed. It’s just a matter of when and to what degree, with the hosing being less extreme the earlier it’s dealt with.

In all likelihood, the city will go bankrupt and have creditors cut services in federal bankruptcy proceedings, thereby imperilling the city’s long-term tax base. State, being unable to go bankrupt, will probably hose creditors more.
Be careful with XCOM2 if you like strategy games... I lost many weekends to that game in college. The expansion pack (War of the Chosen) is well worth the money. Honestly just talking about it now is making me want to reinstall it. I like that game so much that I've actually bought it twice.
Actually that's one way to do things, the two ways being retained mode and immediate mode.

And each has their own use cases and challenges.

Traditionally, however, most well known GUIs (most of the apps people use on the desktop) were done with retained mode libraries (GTK, Qt, Cocoa, and so on).

>So a game loop where the user input is gathered, the model is updated by calculating the next state, and the view is displayed seems to me an instance of MVC.

There's nothing preventing the view being a retained mode UI widget tree -- which is how MVC was commonly implemented iirc.
Before anybody runs away and thinks there's a fundamental insight here, I have to say that all that's really changing is who owns the retained model: application or UI library.

I mean retained by contrast with immediate, as in the early DirectX jargon.

By retained model, I mean the source of truth as to the current state of the UI. Games normally use an immediate mode API, but they still render the UI from a model; it's just that they own the model, whereas with UI toolkits, you generally manipulate a model the UI toolkit maintains and the UI toolkit renders from that model.

Retained mode UIs are much easier to start with. You can get something that looks good up and running very quickly, because you don't need to think through the best representation for your UI - skilled designers and engineers have already done the work, and developed composition and drawing routines so that it all hangs together.

The trouble starts in more sophisticated applications, where the internal model has grown more complex, and UI code is increasingly an exercise in duplicating changes from one model to the other, via reactive techniques like data binding, or more imperatively from events. Having components denormalize state is a recipe for desynchronization bugs.

The problem doesn't totally go away if you move wholesale to immediate mode where the app owns the model, though. There are UI concerns that don't really belong in most application models; things like focus, selection, non-local UI idioms like radio buttons, caret position in text, etc. Doing these things right involves a lot of subtle design. Most app developers are better off handing these concerns to experts who focus on them.
What about taking it with recovery periods e.g. not at the weekends, or on alternate months? What would that do to the risk/benefit?
Agreed. The core code is actually pretty well written considering the concrete backwards compatibility standards enforced by the devs, but most plugins are a total mess (and I'm saying that as a plugin author). I guess it is mainly due to PHP's low bar for entry and PHP's historical (but arguably not now) lack of enforcement of good programming practices.

There is potential for change though. There is a project backed by the core devs (can't remember the name) which will score plugins by their code standard and show the score in the plugin directory.
Nor are these damn rickets.
The difference between interpolation and extrapolation is not that relevant in dimensions higher than 1.
Importance of Venture Capital Funding
Better than work pieces. Sorry boss someone out a 3/8th piece in the 5/8th holder. That $10e6 titanium piece is now scrap. We'll do better next time.
Where's Masculinity Headed? Men's Groups and Therapists Are Talking
But: avoid premature optimisation, it could lead to overly complex abstractions.

Simple, clear structures with little repetition are ideal.

Copy pasted data is painful to work with but still relatively easy to maintain and fix.

Overly complex and unintuitive abstractions are the most difficult to maintain and improve.
I am willing to bet that someday, we will return to our roots: classic communities forming organically around topics without algorithms guiding us along. But until then, let us remain hopeful and vigilant.
Rob Matheson writes for MIT's Technology Review, which has a reputation for massively over-hyping anything done by MIT researchers. Just take the performance claims with a grain of salt until someone who doesn't work for MIT writes about it.
This is close to what Rust is doing, and it's working pretty well, apart from shocking newcomers who expect libstd to be useful on its own.

In Rust, libstd is mainly for interfacing with the compiler and providing interoperability between packages (crates). The wider crate ecosystem is the real standard library, since external crates are as easy to use as the standard library.

For example, the libstd doesn't even have support for random number generation. There's a rand crate, which is now on 6th major breaking version. That's perfectly fine, because multiple versions can coexist in one program, and every user can upgrade (or not) at their own pace. And the crate was able to refine its interface six times, instead of being stuck with the first try forever.
I know that you already got an answer to this effect, but to provide some more information, most data science workflows in Python rely heavily on calls into numerical libraries (numpy, scipy, pandas, tensorflow, pytorch, matplotlib) that are Python wrappers over compiled binaries (mostly C and Fortran, a not-inconsiderable amount of handwritten Assembly), that have been constructed so that the wrapper safely yields the GIL before invoking the underlying binary. This is all the more important when considering libraries like tensorflow or pytorch that may involve complex long-running interaction with training resources across a network. Control is yielded to allow the interpreter to continue carrying out tasks like displaying the ongoing training progress, or loading training data.
I bet car manufacturers wish people would stick to the guidance they distribute for the engines they make. But it’ll never happen. There will never be a professional organisation to weed out bad or fraudulent mechanics, so people are always going to need the basic knowledge to work out when they’re being conned. Medicine, law ... professions that self-regulate are justified in caring that people don’t try to DIY, because they present a credible and reliable way.

You might be tempted to argue protectionism, but that only really flies when some specific job is so completely studied and process-driven that you don’t need the professionals any more. Not exactly the case when you’re talking about interpreting appellate cases or similar, judging by the context of Kerr’s article.

I don’t know what you mean about humility. (Oh - re those new readers. Yes, it’s possible someone will read Law For Dummies and back out recognising the vastness of their incomprehension. But those people were likely to hire a lawyer for real problems already. We’re worried about the people who want to confirm that they’ll be fine without seeking advice. Unless you just lace it with recommendations to seek a lawyer, in which case congratulations, you are a local renting tribunal’s public information officer.)
Show HN: Ive created a new type of puzzle game, hybrid of minesweeper and memory
>This means that python will have native threads that behhave as expected minus true parallel execution, so you shouldn't use those, even though the interface is fairly simple.

Python already has exactly that, and has had that for ages.

>Instead, you should learn to use this weird contraption that is neither multiprocessing nor intuitive multithreading and comes with a cumbersome interface.

It also comes with performance improvements over multiprocess, so there's that.

Besides the "cumbersome interface" is irrelevant, as it would be easy to wrap and forget about it, the same way nobody really uses urllib directly.
Grocery bills can predict diabetes rates by neighborhood
Crickets have hit the high street – can they save the planet?
In order for such an API to work, you'd have to bundle the vast majority of the existing Python runtime.
The default behavior for javascript interacting with the DOM is incredibly slow once the page gets complicated enough. I've certainly seen it first-hand. This may not be a problem you have, and indeed maybe not everybody needs react. But the problems things like react/vue/whatever solve (correctly or not) isn't imaginary.
XCom is a fantastic mobile port of a truly great game. Depending how far you want to stretch the definition of strategy there’s also Stardew Valley.
I will take this opportunity to recommend agadmator’s chess channel on YouTube, I’m thoroughly hooked and have learned so much already from it!

[0] https://www.youtube.com/user/AGADMATOR