HN user

mathiasgredal

93 karma
Posts3
Comments50
View on HN

Not exactly related to Ruby on Rails, but why doesn’t there exist a way to run a Python TKinter app in the browser using WASM?

I have a medium sized dependency-free TKinter program written in Python, and AFAIK there is no way to run it in the browser.

In a society where the abuse of human labour was factored into the cost of the product, the 8-inch fab line would have been shut down, since the cost of the 8-inch wafers would now be prohibitive and not be competitive with the wafers from the 12-inch line. This in-turn would mean that customers would have to switch over to the 12-inch wafers.

We are not supposed to compete on who can abuse their workers the most to improve efficiency and to cut costs. Thankfully, knowledge work does not seem to scale the same way as manual labour, meaning that more abuse of the workers does not mean more output over the long-term.

We have a replacement for CUDA, it is called C++17 parallel algorithms. It has vendor support for running on the GPU by Intel, AMD and NVIDIA and will also run on all your cores on the CPU. It uses the GPU vendors compiler to convert your C++ to something that can natively run on the GPU. With unified memory support, it becomes very fast to run computations on heap allocated memory using the GPU, but implementations also support non-unified memory

Vendor support:

- https://www.intel.com/content/www/us/en/developer/articles/g...

- https://rocm.blogs.amd.com/software-tools-optimization/hipst...

- https://docs.nvidia.com/hpc-sdk/archive/20.7/pdf/hpc207c++_p...

GPGPU programming seems to be in a really good spot with the widespread adoption of C++17 parallel algorithms by GPU vendors.

Now, I can just program against this API using standard C++ code, that interacts with CPU heap allocated memory, and get really performant computation on it using standard map-filter-reduce semantics.

Which begs the question, if attractiveness is such a big predictor of success, why hasn’t everyone evolved to become very attractive? The evolutionary pressure for increased attractiveness should be very high, since it affects so many areas of your life, from career success, to getting partners etc.

Is it that the speed at which we evolve to become more attractive is superseeded by our ability to become better at discriminating for attractiveness?

Low Cost Robot Arm 2 years ago

That was why OP suggested to have 2 motors on each joint, going in opposite direction. The problem with this is that you now have twice the amount of motors.

Go Enums Suck 2 years ago

If you are already using gRPC in your codebase, then you can define your enums with Protobuf, which does much of the same as the tool shown in this article.

Saving Linux 3 years ago

Yeah, but regular package binaries get nuked pretty quickly to make space for new ones, especially on mirrors.

Saving Linux 3 years ago

Sure, but how useful is that when you can’t install any packages, since the package repositories only host packages for supported versions.

When a distro goes EOL, the package repositories typically move to the next supported version and delete all of the old packages.

Could someone enlighten me on how one goes about testing whether a particular crypto implementation is vulnerable to side-channel attacks?

In high school I implemented a basic ECDH key exchange algorithm, which I compiled to WASM, and it can be tested at the bottom of my blog: https://gredal.dev/projects/elliptic-curves

Using only the WASM blob, without looking at the source code for exploits, how would Alice find Bobs private key?

Yeah, people here don’t seem to realize that burning fossil fuels is the primary driver(~90% of CO2 emission) of global warming: https://www.un.org/en/climatechange/science/causes-effects-c...

Still they can’t be inconvenienced the slightest by driving an EV, even though they have a much lower carbon footprint: https://lutpub.lut.fi/bitstream/handle/10024/163938/Kandidaa... (see figure 4)

I reality we could do much better than EV’s, since their production still has a large impact on the environment, and we should instead be focusing on cycling or using public transport, instead of driving everywhere.

I don’t have much hope for this, given what I see here.

I have done this, but for some reason Android SDK has to be weird, so you have to download the SDK seperately and then create a properties file in to root of the project with the path to the Android SDK. Everyone then also has to have their own version of this file, since the path is likely different. You also have to make sure that everyone downloads the same version of the SDK. (also the path to the SDK cannot have any spaces)

Why can it not be like other Gradle dependencies, where Gradle will just download the files automatically?

I get that there is a tradeoff with code density, although if you could have an encoding scheme or extended register mode to alleviate this. I was just thinking that if you have e.g a loop where you run out of registers, since you only have 16, then the compiler will swap the values to memory and reuse that register which creates an instruction dependency that doesnt really have to exist.

If the compiler could use the hidden registers, then the cpu would know that it could run this instruction ahead of time.

It is probably not worth it, since it adds a lot of complexity to an already complex system, which is why it isn’t done.

I have always been bothered with the multinomial layer that picks the next token. It seems like you should be able to stick a classifier in there to detect if the probabilities align with a satisfactory answer and whether the model is unsure of the response. If that is the case, then it should branch out to a bigger model which would compute that single token that it is unsure about, and from that the rest of the response is obvious for the smaller model.

This way you could combine e.g. a 7B parameter model with a 70B parameter model, and get the quality of the larger model while most of the time you are only running the small model.

Edit: You could also store the full probabilities for each token, and then the classifier could detect if it had gone down a bad path, and then unwind the tokens and pick a different path.