You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When generating primes up to 1e12, the process exits with an unusual error code. I imagine it's due to my system not having enough memory, but I thought primesieve might be able to deal with this situation.
pyprimesieve.primes(5245028923, int(1e12))
pyprimesieve immediately sends this code, which I can't really make sense of after a cursory glance at the source of this library and primesieve. It would be nice to know what's going on, but I fear I'll have to use primesieve itself to debug the error as it is now.
The text was updated successfully, but these errors were encountered:
Similar error with the following snippet: pyprimesieve.primes(4, 5)
It checks numbers between start to end-1, so in this case only 4. As 4 is composite, there aren't any primes there.
Instead, it returns an' array of [<NULL>, <NULL>].
Currently detecting via the following; though it's not good code. primes = pyprimesieve.primes(4, 5) if "<NULL>" in str(primes): print("No Primes.") else: print("Are Primes.")
In your case, however, it's likely you're running out of RAM.
Primes from 5_245_028_923 to 20_000_000_000 take ~25.4 GB of RAM.
I'm not familiar regarding the RAM utilization trend, but very optimistically assuming linear (probably very inaccurate), 1e^12 would need ~1,712 GB. And that's optimistic.
When generating primes up to 1e12, the process exits with an unusual error code. I imagine it's due to my system not having enough memory, but I thought primesieve might be able to deal with this situation.
pyprimesieve.primes(5245028923, int(1e12))
pyprimesieve immediately sends this code, which I can't really make sense of after a cursory glance at the source of this library and primesieve. It would be nice to know what's going on, but I fear I'll have to use primesieve itself to debug the error as it is now.
The text was updated successfully, but these errors were encountered: