wrstscrnnm6, to programming
@wrstscrnnm6@mastodon.social avatar

I was getting an error "failed to allocate XXXXXX b"

I copy the number into wolfram alpha to see how much data that really is.

5.3 Zettabytes.

How the hell is this program trying to allocate the equivalent of ... all of the data sent over the internet in a year, five times over?

Somewhere between my terminal and the browser the string of numbers got doubled.

Never have I been so relieved to find out my program was only trying to allocate 53Gb of ram.

wrstscrnnm6,
@wrstscrnnm6@mastodon.social avatar

With a few tweaks I got this working on my desktop. A 16 character puzzle computes in 195s. But it does in-fact use a ton of memory.

like, around 124Gb of ram.

inautilo, to webdev
@inautilo@mastodon.social avatar


Write better CSS with modern CSS · New CSS features can help you streamline your code https://ilo.im/15ynzs


marwi, to webxr German
@marwi@mastodon.gamedev.place avatar

We've made a new features trailer for Needle Engine 3.36 ✨

https://youtu.be/VkcLvnK_aeU?si=2VVXWgnIezKzxKqW

stevensanderson, to github
@stevensanderson@mstdn.social avatar
stevensanderson,
@stevensanderson@mstdn.social avatar

@ramikrispin I think this is it. The Mega Test Scrip creates 1000 different combinations of the rchisq() data and runs it all using different approachs

https://github.com/spsanderson/TidyDensity/issues/414#issuecomment-2053657200

#R

ArneBab, to scheme German
@ArneBab@rollenspiel.social avatar
qgi, to Playdate German
@qgi@mastodon.gamedev.place avatar

Finally got my ! After some serious , my demo now updates 8 times per frame at 50 FPS. That's >400 times per second!
The trick: Instead of iterating over each pixel (bit) individually, I'm doing a bunch of bitwise operations per byte.

A falling sand demo running on the Playdate handheld console.

Sevoris, to scifi

One of my favorite hard topics that I love to work within (even if I am terrifically starved for time to do much about this at the moment) are wormhole networks.

They have interesting geometry constraints once you add real star maps, challenges when it becomes time to figure out how many connections you need to connect what places while observing construction and shape constraints…

it is the kind of computer science that tickles my brain extra being scifi nerdy

nucliweb, to random
@nucliweb@webperf.social avatar
synlogic, to golang
@synlogic@toot.io avatar
orhun, to rust
@orhun@fosstodon.org avatar

Here is how you can search strings blazingly fast in Rust! ⚡️🔍

🦀 memchr: Optimized string search routines for Rust.

📚 Documentation: https://docs.rs/memchr

⭐ GitHub: https://github.com/BurntSushi/memchr/

synlogic, to programming
@synlogic@toot.io avatar

need an extra hand for your Go codebase?

need perf improvements to your software?

have a legacy Heisenbug in need of squashing?

want a mature, senior programmer with multiple areas of expertise and a proven & public record of shipping?

have budget for professional?

can they work remotely 100%?

CONTACT ME NOW

I'd love to jump in fast and help! I solve and ship












j9t, to random
@j9t@mas.to avatar

Website Optimization Measures, Part XXII:

Web design is a process, running our own websites is awesome, and together it means there’s always something to tweak and improve and optimize. Select things I’ve done over the last few months.

https://meiert.com/en/blog/optimization-measures-22/

janriemer, to math

Did you know that for natural numbers:

{x: >= 0, y = 2ⁿ}

the follow holds true:

x mod y

is equal to

x & (y - 1)

Example:

31882511 mod 1024

is equal to

31882511 & 1023

(where mod is the modulo operation and & is bitwise-and)

janriemer, to random
cliffle, to web
@cliffle@hachyderm.io avatar

Spent the past few evenings on a very different kind of performance optimization: making my website really, really fast -- with a focus on people with slower, higher-latency connections.

I had to learn some things to pull this off, and I thought they might help others, so I've written the process up in a new blog post:

https://cliffle.com/blog/making-website-faster/

Includes some animated GIFs of the page load experience so you can see how bad it can be!

stevensanderson, to random
@stevensanderson@mstdn.social avatar

#R

I just updated my function ckurtosis (cumulative kurtosis) from an code to a approach, not because I don't like *apply functions but because it greatly speeds things up.

stefano, to tech
@stefano@bsd.cafe avatar

This morning, a VPS hosting a small e-commerce site (powered by WooCommerce on Ubuntu 22.04) experienced another out-of-memory issue. A colleague (one of the developers) urgently called me, asking to upgrade the VPS due to excessive load.

I pointed out (again, as has often happened in recent weeks) that a VPS with 32GB of RAM (!!!) and 16 dedicated cores (!!!) should not run out of memory with just five simultaneous visits to a small e-commerce site. We host much larger and busier websites on much smaller VPSs. There's likely a WordPress module with a leak, or some interaction between modules causing this issue.

The response: Okay, but just add more RAM and power to solve it.

The illusion of "infinite resources" in the Cloud has led to poor development habits. Sometimes I wonder how much energy and resources we waste (and pollution we generate) due to a lack of basic optimization.

synlogic, to programming
@synlogic@toot.io avatar

I'm writing a new big book on software performance and scalability

If you'd like to see early chapter drafts from it, and potentially give me a little feedback (or answer a few simple questions I ask of you, about your impressions), in private? please let me know

I would give you a free copy of final ebook


















j9t, to random
@j9t@mas.to avatar

From the archives:

One-Dimensional Website Optimization Considered Harmful:

https://meiert.com/en/blog/pareto-optimization/

ocramz, (edited ) to random
@ocramz@sigmoid.social avatar

https://github.com/ocramz/assignment-riemann-opt turns out you can use pytorch for combinatorial optimization - sort of 🙃

ConfluxHQ, to random

🚀 Meet Audun Fauchald Strand and Truls Jørgensen, the dynamic duo of Principal Engineers at NAV (Norwegian Labour and Welfare Administration). With a joint passion for fostering sustainable organizations, they're on a mission to strike the perfect balance between effective team leadership and crafting simple, efficient code. 🌟👨‍💻

Read more ▶️ https://www.linkedin.com/feed/update/urn:li:activity:7142459692454211584

JSMuellerRoemer, to programming

A work-related post for a change: Our team is planning to expand in the field of automatic, robust geometry processing. If you are interested in applied research in that field with the option of a PhD, you can find the job posting (German only for now) here: https://jobs.fraunhofer.de/job/Darmstadt-Wissenschaftlicher-Mitarbeiterin-im-Themenbereich-Geometrieverarbeitung-und-Optimierung-64283/1010285501/

Please boost for reach

linuxmagazine, to opensource
@linuxmagazine@fosstodon.org avatar
janriemer, to ArtificialIntelligence

Ant colony optimization algorithms

https://en.wikipedia.org/wiki/Ant_colony_optimization_algorithms

"[T]he ant colony optimization (ACO) is a technique for solving computational problems which can be reduced to finding good paths through . Artificial ants stand for multi-agent methods inspired by the behavior of real ants. The pheromone-based communication of biological ants is often the predominant paradigm used."

gregeganSF, to random
@gregeganSF@mathstodon.xyz avatar

The volume of a ball of radius r in n dimensions is

B(n,r) = π^{n/2}/Γ(n/2+1) r^n

If you look at the volumes of the balls (blue circles) inscribed inside hypercubes with edge length 1 and volume 1, they go to zero as n gets larger:

lim n→∞ B(n,½) = 0

If you look at the volumes of the balls (red circles) that circumscribe each hypercube (of diagonal √n), they go to infinity:

lim n→∞ B(n,½√n) = ∞

But what if you always choose the radius of an n-ball so that its volume is exactly 1 (green circles)?

r₁(n) = Γ(n/2+1)^{1/n} / √π

This gives us B(n,r₁(n)) = 1

It turns out that:

lim n→∞ (r₁(n) - √[n/(2eπ)]) = 0

In other words, r₁(n) is asymptotic to a multiple of √n, so it approaches a fixed ratio with the length of the diagonal of the hypercube with the same volume.

Projections of n-cubes for n=2 to 12 so that their outline is a 2n-gon. Blue, green and red circles centred on the projection show the radii of the inscribed ball, the volume-1 ball, and the circumscribed ball.

jef,

@johncarlosbaez @gregeganSF

Curse of Dimensionality
https://en.wikipedia.org/wiki/Curse_of_dimensionality

"Dimensionally cursed phenomena occur in domains such as numerical analysis, sampling, combinatorics, machine learning, data mining and databases. The common theme of these problems is that when the dimensionality increases, the volume of the space increases so fast that the available data become sparse. In order to obtain a reliable result, the amount of data needed often grows exponentially with the dimensionality. Also, organizing and searching data often relies on detecting areas where objects form groups with similar properties; in high dimensional data, however, all objects appear to be sparse and dissimilar in many ways, which prevents common data organization strategies from being efficient. "

  • All
  • Subscribed
  • Moderated
  • Favorites
  • Leos
  • Durango
  • ngwrru68w68
  • thenastyranch
  • magazineikmin
  • hgfsjryuu7
  • DreamBathrooms
  • Youngstown
  • slotface
  • vwfavf
  • PowerRangers
  • everett
  • kavyap
  • rosin
  • anitta
  • khanakhh
  • tacticalgear
  • InstantRegret
  • cubers
  • mdbf
  • ethstaker
  • osvaldo12
  • GTA5RPClips
  • cisconetworking
  • tester
  • normalnudes
  • modclub
  • provamag3
  • All magazines