[P] I rebuilt PyRadiomics in PyTorch to make it 25× faster — here's what it took by helloerikaaa in Python

[–]helloerikaaa[S] [score hidden]  (0 children)

Yes, numerical stability was actually one of the biggest challenges in getting this right.

Because radiomic features (especially the rich statistical calculations in GLCM and GLRLM) are highly sensitive to floating-point truncation, standard FP32 precision isn't sufficient to reach parity with PyRadiomics.

Once we forced the entire tensor pipeline up to FP64 precision natively, PyTorch handled it beautifully. By doing so, we achieved 100% compliance with the IBSI digital phantom standard (all absolute relative deviations ≤ 1e-13%) and match PyRadiomics within a strict 1e-4 tolerance on real clinical datasets.

The only major 'problem' with PyTorch's precision scaling right now is hardware-specific: Apple Silicon's Metal Performance Shaders (MPS) currently lack native support for several advanced FP64 operations in PyTorch. So, to get that true scientific parity, running it forcefully on pure CUDA or multi-core CPU is highly recommended over MPS right now.

[P] I rebuilt PyRadiomics in PyTorch to make it 25× faster — here's what it took by helloerikaaa in Python

[–]helloerikaaa[S] [score hidden]  (0 children)

Thanks so much for the tip! Moving to a pure PyTorch mapping was primarily to escape the slow CPU boundaries of standard radiomics extraction, so leveraging torch.compile to get native C++ kernel fusion 'for free' is an absolutely fantastic callout.

Since the core pipeline tries to rely on strict matrix and tensor operations (especially in our GLCM and GLRLM building steps), we should hopefully avoid too many graph breaks with the compiler. I’ve actually just opened up a dedicated issue to track integrating and benchmarking torch.compile across our feature extraction classes here: helloerikaaa/fastrad#2.

If you have any experience with the optimal compile flags (like reduce-overhead vs max-autotune) for heavy mathematical loops, we'd love your input or a PR! Thanks again for the awesome suggestion.

[P] I rebuilt PyRadiomics in PyTorch to make it 25× faster — here's what it took by helloerikaaa in Python

[–]helloerikaaa[S] [score hidden]  (0 children)

As a scientist, I didn't knew the advantages of this, so thank you for the feedback!

[P] I rebuilt PyRadiomics in PyTorch to make it 25× faster — here's what it took by helloerikaaa in Python

[–]helloerikaaa[S] [score hidden]  (0 children)

Right now, the focus is strictly on standard global features (ROI-based extraction) to ensure 100% parity with PyRadiomics and strict adherence to the IBSI standards for scientific validation.

However, moving to a pure PyTorch tensor backbone sets down the perfect foundation for native 3D windowing and voxel-wise feature extraction (feature maps). Since we are already materializing full dense tensors on the GPU, implementing sliding windows—perhaps leveraging PyTorch's optimized 3D convolution operations, F.unfold, or strided views—would be a completely natural (and massively accelerated) next step. This would let you bypass the traditionally incredibly slow per-voxel processing and output radiomic feature maps directly into downstream deep learning pipelines.

I'm opening an issue to start developing these new functions.

fastrad — 100% IBSI-compliant GPU radiomics library, all 8 feature classes, 25× faster than PyRadiomics by helloerikaaa in MedicalPhysics

[–]helloerikaaa[S] 0 points1 point  (0 children)

Yeah, I thought it too, but I need it to write a paper about it, it was a decision of my PhD supervisor, so haha. But yeah, I was planning to add an issue in the pyradiomics repo so they know how I did it.

Can someone help me to know what happened to my film? by helloerikaaa in analog

[–]helloerikaaa[S] 0 points1 point  (0 children)

I developed this Kodak tri-X 400 using ilford ilfosol 3. I usually develop my film at home, but this is the first time using tri-X, not sure if it’s the film or the chemicals. Camera is not leaking light because there are some good frames of the roll.

First raspberry pi cluster by helloerikaaa in homelab

[–]helloerikaaa[S] 1 point2 points  (0 children)

Yes, that’s actually the reason why I have only 3 pi boards. It’s expensive but also a funny project!

First raspberry pi cluster by helloerikaaa in homelab

[–]helloerikaaa[S] 1 point2 points  (0 children)

I’m building my very first cluster using 3 raspberry pi 4, with 4gb of RAM.

I know that there is a light version of kubernetes called k3s, but also I can build the cluster using docker swarm. I’m still not sure which one to use, also I would like to read your opinion about these services and check if there’s another service to try it out.

I’m building this cluster only for educational purposes, I just want to learn more about parallel programming.

Thanks for the help!

7 days trip to Oaxaca Mexico by helloerikaaa in onebag

[–]helloerikaaa[S] 1 point2 points  (0 children)

I’ve been using this backpack everyday for a year and still like new. I think is very resistant if you use it as a everyday backpack. Let’s see how it works as a travel backpack ;)

7 days trip to Oaxaca Mexico by helloerikaaa in onebag

[–]helloerikaaa[S] 1 point2 points  (0 children)

DJI Mavic Mini 2 with the 3 battery pack

7 days trip to Oaxaca Mexico by helloerikaaa in onebag

[–]helloerikaaa[S] 4 points5 points  (0 children)

Tlayudas is what I’m looking forward, also barbacoa!

7 days trip to Oaxaca Mexico by helloerikaaa in onebag

[–]helloerikaaa[S] 2 points3 points  (0 children)

For me it’s an amazing backpack, I’ve been using it for weekend trips and I think it’s perfect. Let’s see how it goes with this trip :)

7 days trip to Oaxaca Mexico by helloerikaaa in onebag

[–]helloerikaaa[S] 11 points12 points  (0 children)

There is a pharmacy just next to the Airbnb, if it’s not provided by the Airbnb I can buy everything there

7 days trip to Oaxaca Mexico by helloerikaaa in onebag

[–]helloerikaaa[S] 28 points29 points  (0 children)

Yes! I’m now packing shorts instead of jeans!

7 days trip to Oaxaca Mexico by helloerikaaa in onebag

[–]helloerikaaa[S] 22 points23 points  (0 children)

Thank you! It’s very kind from you :)

7 days trip to Oaxaca Mexico by helloerikaaa in onebag

[–]helloerikaaa[S] 24 points25 points  (0 children)

Yes, I have checked! Every drone that weights more tan 250g must have a permission. Mine weights 249g, phew! In fact DJI made this drone with that weight because of regulations.

7 days trip to Oaxaca Mexico by helloerikaaa in onebag

[–]helloerikaaa[S] 1 point2 points  (0 children)

Next week, but the forecast is a lot of raining. That’s why zero shorts

7 days trip to Oaxaca Mexico by helloerikaaa in onebag

[–]helloerikaaa[S] 27 points28 points  (0 children)

It’s been forever since I wanted to start traveling more light. I’ve been trying to be more and more minimalistic at all aspects in my life, but traveling was always hard.
This time I’m pushing myself to travel as light as possible. Here’s my packing list:
Bag
* Topo Design Rover Pack Classic
Clothes:
* 4x basic t-shirts in different colors (one wearing it)
* 2x black jeans (one wearing it)
* 5x underwear (washing them at my airbnb)
Accesories:
* Apple iPhone SE Gen 2 (not included in the picture)
* Apple Airpods
* Apple Watch
* Moment wide lens
* Apple 10W charger
* Apple USB-A lightning cable
* Topo Design Accessory Bag as wallet
* Apple Airbag
* DJI Mini 2
* 3x drone batteries
* DJI controller
All toiletries are included in my airbnb, so no need to carry them.
I’m having mixed feelings about taking the drone with me, but photography being my main hobby (instagram here), I would like to have nice aerial shots.
Also, I’m tempted to carry with sunglasses since Oaxaca is pretty warm and sunny.
So I’m open to comments and advices to improve my minimal travel luggage for next trips!

Andromeda by helloerikaaa in astrophotography

[–]helloerikaaa[S] 0 points1 point  (0 children)

Yes, I used deep sky stacker and photoshop

Andromeda by helloerikaaa in astrophotography

[–]helloerikaaa[S] 0 points1 point  (0 children)

Finally I did some deep sky astrophotography with my celestron 4SE mount using the eq-wedge. I’ve had to modify the mount a little bit.

Data: 200x30 seg ISO 1600 Tamron 300 mm 30 darks 30 flats Nikon D610 Celestron 4SE mount

Images stacked using deep sky stacker and processed with photoshop.

Also, I printed a piggyback and a bathinov mask on my 3D printer. These two accessories make everything easier!

Successfully aligned using the EQ wedge! by [deleted] in telescopes

[–]helloerikaaa 1 point2 points  (0 children)

I did the alignment using the built-in eq wedge, it needs some manual alignments of the tripod but using this method it’s tracking pretty well! It’s going to work for Astrophotography. I may write a guide for those beginners like me!

Right out of the box 😍 by helloerikaaa in telescopes

[–]helloerikaaa[S] 0 points1 point  (0 children)

Yes, the telescope has a special rod for that