Better HN
topnewbestaskshowjobs
Log inSign up

nicebyte

223 karma · joined Dec 18, 2014 (11y ago) · 96 submissions

http://gpfault.net/ http://twitter.com/nice_byte http://github.com/nicebyte nicebyte at gpfault.net
Submissions

comment 5mo ago · link · parent

general rule of thumb is that you never want gamma-corrected values if you intend to be doing any sort of math with them. the only exception is when you want to match the behavior of softwares that actually do all the math with pixel values in sRGB space (I think that's what photoshop does but don't quote me on that).

comment 5mo ago · link · parent

there isn't much that is "arcane" about gamma correction itself (as in, the math itself is really simple).

at the fundamental level, if a surface is illuminated with one lightbulb and we add another light bulb, the difference is exteremely noticeable to the human eye. if we add one more lightbulb to a surface that is already illuminated by a hundred light bulbs, there will be no perceptible difference. the exact response can be modeled with a pretty simple power law (with a modification in the low range, as the article mentions).

that's all there really is to "gamma correction". it's a hack that exploits this quirk of the human visual system in order to more efficiently allocate bits for encoding different "lightness" values.

all of the confusion and bugs stem from one or more of the systems in the chain that forms the final image, making an incorrect assumption about what the others are doing. it's a bit like coordinate spaces in that regard.

comment 5mo ago · link · parent

that just sounds like DNS but more centralized and not super human-friendly...

comment 5mo ago · link · parent

but dynamic DNS is a thing. I've had setups for it since god knows how long, though admittedly not on my phone.

comment 5mo ago · link · parent

I am confused why this is needed.

> IP addresses can break, without warning, and it's outside of your device's control.

We have DNS?

> Keys, however, are created & controlled by you. They stay the same as your device moves, and are yours to throw away, or not.

So are domain names? This page does not do a good job of helping me find what it is that I'm missing.

comment 5mo ago · link · parent

If done right, this is more like a monthly bus pass

comment 5mo ago · link · parent

when you re-crop a photo or use the perspective tool, you are literally distorting the image. not to mention, all of the processing that happens in modern cameras before you even see the image. in the case of a modern smartphone in particular, I think it's fair to say that you never really see the "real" image as captured by the CCD sensor, and even if you did you would not like it anyway.

comment 5mo ago · link · parent

they're technically not wrong. C is literally an "abstraction" of the machine. As we know, the whole point of an abstraction is to ignore the multitude of details :-)

comment 5mo ago · link · parent

250k for base pay is about in line with median I'd say.

If 250k was the total comp (taking into account bonus/stocks/what have you) then yeah, you definitely should have negotiated.

comment 6mo ago · link · parent

"outgroup"? what outgroup? we're talking about inanimate objects here. by your own logic, you treat your home appliances as an outgroup so you must be secretly a dangerous psychopath. or do you thank your microwave after heating leftovers?

comment 7mo ago · link · parent

it's a neat experiment but I think it's ultimately flawed because color is usually perceived in context, and depending on context I could easily see anyone reinterpreting the hues they labeled "green" in this test as blue, and vice versa.

EDIT: in general, blue is a pretty fascinating color. yes, many cultures have a somewhat blurry distinction between blue and green. Some others seem to differentiate shades of blue that others don't (i.e. in Russian "голубой" and "синий" refer to distinct colors but in English those would be just shades of blue). I guess there's something about photons in that energy band that messes with perception. https://en.wikipedia.org/wiki/Non-photo_blue

comment 7mo ago · link · parent

> There is no consequence for choosing blue

there are consequences in both cases.

43.

Introduction to Spherical Harmonics for Graphics Programmers(gpfault.net ↗)

4 points · by nicebyte · 7mo ago · discuss

comment 9mo ago · link · parent

I've found Trellis specifically to be very "over-promise and under-deliver".

Nothing i tried with it got even close to th level of quality that they were advertising - felt like a bunch of examples were hand-picked, at best.

comment 9mo ago · link · parent

jumps is another one. jmp can have many encodings depending on where the target offset you're jumping to is. but often times, the offset is not yet known when you first encounter the jump insn and have to assemble it.

comment 9mo ago · link · parent

> I want a single-line malloc with zero care about usage flags and which only produces one single pointer value

That's not realistic on non-UMA systems. I doubt you want to go over PCIe every time you sample a texture, so the allocator has to know what you're allocating memory _for_. Even with CUDA you have to do that.

And even with unified memory, only the implementation knows exactly how much space is needed for a texture with a given format and configuration (e.g. due to different alignment requirements and such). "just" malloc-ing gpu memory sounds nice and would be nice, but given many vendors and many devices the complexity becomes irreducible. If your only use case is compute on nvidia chips, you shouldn't be using vulkan in the first place.

comment 9mo ago · link · parent

> Not sure if this is an "oh, no" event.

it's not.

descriptor sets are realistically never getting deprecated. old code doesn't have to be rewritten if it works. there's no point.

if you're doing bindless (which you most certainly arent if you're still stuck with descriptor sets) this offers a better way of handling that.

if you care to upgrade your descriptor set based path to use heaps, this extension offers a very nice pathway to doing so _without having to even recompile shaders_.

for new/future code, this is a solid improvement.

if you're happy where you are with your renderer, there isn't a need to do anything.

comment 9mo ago · link · parent

just use the vma library. the low level memory allocation interface is for those who care to have precise control over allocations. vma has shipped in production software and is a safe choice for those who want to "just allocate memory".

comment 9mo ago · link · parent

some of this is what's khronos standards are theoretically supposed to achieve.

surprise, it's very difficult to do across many hw vendors and classes of devices. it's not a coincidence that metal is much easier to program for.

maybe consider joining khronos since you apparently know exactly how to achieve this very simple goal...

comment 9mo ago · link · parent

assembler is far from trivial at least for x86 where there are many possible encodings for a given instruction. emitting the most optimal encoding that does the correct thing depends on surrounding context, and you'd have to do multiple passes over the input.

comment 11mo ago · link · parent

shameless plug: if you want to understand the content of this post better, first read the first half of my article on jumps [1] (up to syscall). goes into detail about relocations and position-independent code.

[1] https://gpfault.net/posts/asm-tut-4.html

comment 1y ago · link · parent

including ai generated illustrations in your articles or presentations is very cringe

comment 1y ago · link · parent

my comment isn't about things being written using c/make/whatever, it's precisely about the faulty assumption that complexity is needless.

comment 1y ago · link · parent

yeah no. I've mainlined dwm + dmenu all the way back in 200x, I've written tons of makefiles and have the scars to prove it.

These days I'm off of this minimalism crap. it looks good on paper, but never survives collision with reality [1] (funny that this post is on hn front-page today as well!).

[1] http://johnsalvatier.org/blog/2017/reality-has-a-surprising-...

comment 1y ago · link · parent

I bet 90% of the reason this is on the front page is the Berkeley mono font. the system itself sucks.

comment 1y ago · link · parent

How did you draw that conclusion from reading the contents of the link? This is a benchmark.

> We evaluate model performance and find that frontier models are still unable to solve the majority of tasks.

comment 1y ago · link · parent

I already knew a lot of what was written here but for some reason reading this made me uninstall bumble.
1234