spatialdata-io icon indicating copy to clipboard operation
spatialdata-io copied to clipboard

We're storing spot locations as int64 (and maybe more) - should be sth smaller

Open timtreis opened this issue 1 year ago • 3 comments

timtreis avatar Oct 10 '24 15:10 timtreis

Good point, int32 should be more than enough. Also, according to this https://github.com/scverse/spatialdata/issues/187, int64 are not available in JS, another reason to use int32 (please @ilan-gold confirm this).

LucaMarconato avatar Oct 10 '24 20:10 LucaMarconato

@ilan-gold had strong opinions on this in general - and realistically we can probably get away with sth that covers all use cases? Maybe we could automatically do that within spatialdata-io. Wdyt?

timtreis avatar Oct 14 '24 07:10 timtreis

@LucaMarconato unbenkownst to me 64 bit integers were available in JS before https://github.com/scverse/spatialdata/issues/187, but not by very long so a lot of software didn't handle them (yet and still). I can implement a fix for this specifically in vitessce, no problem. but in general, i think this should perhaps be checked a bit? maybe even just warning people? it's double the data for little good reason. For example, you could provide a global setting to allow people to opt-in to writing as 32 bit integers (and then switch it to 32 bit by default after a period of time)

I wouldn't say this is a blocker,but more a suggestion/RFC

ilan-gold avatar Oct 14 '24 08:10 ilan-gold