hsfzxjy

Joined 5 years ago

Karma
232
Submissions
84
Member since
Feb 9
github.com/hsfzxjy i.hsfzxjy.site
View on Hacker News

Recent submissions

Comment · 11 days ago
I think `__slots__` should do the exact thing?
Comment · 1 month ago
Comment · 1 month ago
I have added a prober program which can run specific tests on linux and generate reports. This should be a nice start.
Comment · 1 month ago
Let's play Doom on NPU!
Comment · 1 month ago
Yes. But WSL doesn't come with NPU passthrough, so I still can't test the hardware-specific behavior. Cross-compiling the project with WSL is plausible. I will try it and leave for the community to do verification.
Comment · 1 month ago
Comment · 1 month ago
Thanks! I can observe similar behaviors on my laptop. FP32 operations are sometimes siliently lowered to a sequence of (FP32->FP16)->(FP16 OP)->(FP16->FP32), causing precision loss. It further frustrated me during npunlock development. Changing custom SHAVE OP from FP16 -> FP32 also changes the blob structure, and I have to explore different binary patching strategy.

As for the interesting cost variance for reshape you've mentioned, I guess surrounding context is the cause. The NPU compiler might adjust the data layout to match successive OPs' requirements. But, yes, that's annoying~

Studying DPU is not my current priority, but I may dig it up in the future to understand its invocation descriptor, and hopefully to discover more interesting stuff. I hope this project ends up being useful to you!

Comment · 1 month ago
Author here. Feel free to ask any questions :)
Comment · 1 month ago
The main use is enabling developers to write their own NPU kernels according to their respective need, instead of picking workaround from what Intel provides in OpenVINO. I think the project would benefit three scenarios:

1. Implement uncommon NN operators.

2. Implement a high-precision (FP32, etc.) version of existing OpenVINO operators for numerically sensitive usage.

3. Implement a mega kernel that fuse several small kernels together to reduce SHAVE invocations, and potentially improve performance.

But most importantly, it gives you more control over the hardware you own. That control IMO should have been yours from day one you bought the machine.

Comment · 1 year ago
To derive "The XOR trick" I think both *associativity* and communitativity are needed.

That is, one should also prove a ^ (b ^ c) = (a ^ b) ^ c. Instinctive, but non-trivial.

Comment · 1 year ago
Looks cursed to me.

But TIL dollar sign $ is also valid character for identifiers.

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton