HNHacker News
TopNewBestAskShowJobs

cshenton

387 karma · joined January 27, 2016

I write statistical software https://github.com/cshenton
submissionscomments
cshenton··on Computer Graphics from Scratch
Congrats on getting your book published! I will definitely be ordering a copy :)
cshenton··on Ask HN: How to do cross platform GUI?
Left of field, but game engines have figured out translating a single set of UI APIs to multiple graphics backends already.

Alternatively you could use a compatibility version of OpenGL, like 3.3 which will run on any desktop OS, then use a windowing lib like glfw and UI framework like Dear ImGui which is graphics API agnostic. I use this particular combination all the time and it never lets me down. Sokol is another options which is a very thin layer over many graphics APIs.

cshenton··on Factorio 1.0
Coffee Stain is the publisher for Deep Rock Galactic, Ghost Ship Games are the developer.
cshenton··on Zig cc: A drop-in replacement for GCC/Clang
Thanks for all your effort on the project. By far my best experience with zig was writing an OpenGL renderer on windows which then “just worked” when I cloned it ran `zig build` on my Linux machine. Felt like magic.
cshenton··on From models of galaxies to atoms, simple AI shortcuts speed up simulations
The real question is how much the speed up is due to the low quality of the initial implementation. I’ve seen speed ups of 100-1000x on the same hardware. Academic simulation code is often bad.
cshenton··on Time safety is more important than memory safety
The 737 max? Yeah probably.
cshenton··on How Do Bullets Work in Video Games?
If you want to read further on this topic the term is “continuous collision detection”. Bullet physics is a good open source physics library with it implemented.
cshenton··on Show HN: A simple garbage collector for C
Check out Zig if you’re looking for a C replacement with a go style defer. It also interops about as well with C as C does.
cshenton··on Julia v1.3
Julia feels like a scripting language but every function is effectively a template. I prototype lots of high perf stuff in it because it gives you control of memory layout and what gets evaluated at compile time, so it'll get you within spitting distance of an optimised c++ implementation but with 10x better iteration speed. Thoroughly recommend it to any Comp Sci / ML researchers.

Only thing I'd wish for is better control of memory layout for mutable structs, but I know that's unlikely since that's one thing that the Julia folks want to keep abstracted from the user.

cshenton··on HackPPL: A universal probabilistic programming language
Not sure why one would use this over Uber’s Pyro, which is built in python on top of Pytorch and has a similar feature set.

Also worth pointing out that, like all current gen PPLs, the word “Universal” is highly misleading, as only variables that are the result of a sample statement can be observed (since HMC, IS, and others require closed form conditional likelihood’s for observed variables). This rules out use cases such as observing noiseless aggregates of noisy signals (any workaround is a fudge and will put strain on the inference algorithms capacity for search).

Only a PPL with support for likelihood free inference techniques (few of which work very well as of today) could be considered truly “Universal”.

cshenton··on Speeding up independent binary searches by interleaving them
If I had to hazard a guess, I’d say the conditional move means that both next values are prefetched into cache, whereas a branch means that fetch doesn’t happen until the comparison is made.
cshenton··on Leak of Microsoft Salaries Shows Fight for Higher Compensation
Cost of living adjusted salaries are what matters, and London has SV level cost of living at way lower salaries.
cshenton··on Leak of Microsoft Salaries Shows Fight for Higher Compensation
London salary to cost of living ratio is terrible. I made a better real income, and at a lower level, in Australia, which many people leave for better salaries in SV.
cshenton··on Comparisons in C++20
Game? Sure, if you’re willing to spend a non trivial amount of time integrating with a graphics API, but that’s true of most non C++ languages. Kernel? Probably not, AFAIK there’s no subset of Julia that can run without an OS (like for rust and C++).
cshenton··on Composable multi-threaded parallelism in Julia
Julia is already insanely productive for CS and statistics research and this will only make it more so. Super excited to see how this will be used, especially in PPLs, as algorithms like PMCMC benefit hugely from this kind of cooperative, interruptible concurrency.
cshenton··on Composable multi-threaded parallelism in Julia
I started using in it earnest after 1.0 and can honestly say that it's super stable and easy to write and debug errors. The only "bugs" I've had with it have stemmed from abuse/misunderstanding of the dispatch system, and you can write a lot of Julia without running into those kind of user mistakes.
cshenton··on Statistics with Julia [pdf]
One reason I really like the 1 based indexing is that I can have a UInt index and 0 can act as a sentinel value. Really nice for writing things like vector embedded linked lists.
cshenton··on Statistics with Julia [pdf]
Julia code gets compiled native via LLVM so it is about as fast as other natively compiled languages.
cshenton··on D is being used for autonomous driving research – Audi and Mercedes
Julia is the fastest (in speed achievable in a short dev time) language I’ve ever used. Especially for any scientific computing workloads.
cshenton··on Go Creeping In
Julia is the new scientific computing language in the same way Go is the new enterprise dev language.
cshenton··on Deep learning may need a new programming language
Have you used Julia recently? Vectorised operations are just as fast relative to hand written loops as c and FORTRAN, you just need to appropriately annotate @inbounds and @simd. Sure that’s more work, but removing safety checks should be explicit.
cshenton··on A Programming Language Underdog
Does nim have a concurrency story yet? That’s what gave me pause last time I checked it out.
cshenton··on Coca-Cola buys Costa Coffee for £3.9bn
The Economist is the closest thing I can think of. They seem to be doing fine so maybe it's a good business model.
cshenton··on Mistakes C/C++ Devs make writing Go
Sure it will, scientific computing is rife with potentially very large intermediate matrices/tensors of data that need to be deallocated. In C++ I can explicitly free that memory, and in higher level frameworks, like tensorflow, dependency properties of the computational graph as used to figure out the earliest point in time a tensor can be deallocated.
cshenton··on Mistakes C/C++ Devs make writing Go
Yeah that's about right. Go wont fit the bill if you can't trust the garbage collector (often true for scientific computing), or if you're not running your code on a full OS (like if you were writing an OS / embedded code).

Since Go is easier to learn, it probably couldn't hurt to learn it, then turn to Rust if it's not powerful enough for your use case.

cshenton··on Time Series Prediction Using LSTM Deep Neural Networks
For anyone considering this, LSTM only starts to pay off if you have many many time series. For a single time series like this one you’re better off using classical time series approaches like ARIMA or other Gaussian state space models.
cshenton··on Notes on the Go2 Generics Draft
It’s weird to see complaints about code generation causing a too big code base at compile time when code generation is exactly what a compiler will do behind the scenes for generics.
cshenton··on Solve Less General Problems
Isn’t this the difference between computer science and software engineering courses?
cshenton··on The magic of asyncio explained
For me it had the opposite effect.

Working with async-await syntax was the last straw that made me finally go "there's got to be a better way" and find a language can handle concurrency without the semantic overhead (in my case Go, but there are others).

cshenton··on The Bullshit Web
Reading mode on safari does this.
← PreviousPage 2 of 5Next →