mersenneforum.org  

Go Back   mersenneforum.org > Factoring Projects > FactorDB

Reply
 
Thread Tools
Old 2020-01-18, 04:56   #1607
richs
 
richs's Avatar
 
"Rich"
Aug 2002
Benicia, California

5×229 Posts
Default

Quote:
Originally Posted by MisterBitcoin View Post
Most of them require SIQS, so i am at ~50 to 60 canidates per hour.
Using an offset from 5k, so we shouldn´t get into trouble :)
Right after mentioning it. Karma~

Code:
 Worker collisions...........: 1
Not me, I'm working 1-1000.....
richs is offline   Reply With Quote
Old 2020-01-18, 17:23   #1608
chris2be8
 
chris2be8's Avatar
 
Sep 2009

191110 Posts
Default

I've had a couple of systems working on C83s etc for a few months. They check if a number is done immediately before starting work on it so real collisions causing wasted work are rare. Carry on by all means.

But right now one is busy trying to clear C70-79. So even less likely to collide.

Or you could work on 80-82 digits. Or a higher range such as c90 (someone else is working on C89).

Chris
chris2be8 is offline   Reply With Quote
Old 2020-01-18, 19:17   #1609
MDaniello
 
MDaniello's Avatar
 
May 2019
Rome, Italy

418 Posts
Default

I wanted to work on those composites too, but my system is quite slow so i was thinking about looking for factors up to 15-25 digits, depending on the sizes, to get the low-hanging fruits.
I've found that about one third of the composites (i tried sampling from 80 to 120 digits, skipping by 10 each time) has a factor up to 25 digits, and around 3% has one up to 15 digits.

Is that a sensible approach? Or would i be better off SIQSing them all, even if that would factor less composites per hour?
MDaniello is offline   Reply With Quote
Old 2020-01-18, 21:59   #1610
richs
 
richs's Avatar
 
"Rich"
Aug 2002
Benicia, California

100011110012 Posts
Default

Quote:
Originally Posted by MDaniello View Post
I wanted to work on those composites too, but my system is quite slow so i was thinking about looking for factors up to 15-25 digits, depending on the sizes, to get the low-hanging fruits.
I've found that about one third of the composites (i tried sampling from 80 to 120 digits, skipping by 10 each time) has a factor up to 25 digits, and around 3% has one up to 15 digits.

Is that a sensible approach? Or would i be better off SIQSing them all, even if that would factor less composites per hour?
I’d use YAFU which searches for factors before SIQS or NFS.
richs is offline   Reply With Quote
Old 2020-01-19, 16:06   #1611
EdH
 
EdH's Avatar
 
"Ed Hall"
Dec 2009
Adirondack Mtns

7×13×37 Posts
Default

If someone is interested in doing some light ECM only, I have a Python3 script that does just that. In fact, I have the script running in four threads on an rPi that won't run YAFU. It basically grabs a composite and runs a few curves at some levels. For those composites that fail to produce factors, you are causing extra ECM effort when the composite is run later, but if you leave the level set to 3 or less, that's not too much extra and that extra still might hit a lucky catch. Last time I checked my rPi, it seemed to be running at about a 50% success rate.

There is no dupolication checking, so the more you run it in a particular region (offset), the lower the success rate. You may wish to change the values if the success rate is low.

Here's the Python code:
Code:
#!/bin/python3/

compNum = 100 # Number of composites to run
compSize = 83 # Size of composites to run
ranNum = 100 # Number for random count
offset = 15000 # offsets random choice into the chosen size
level = 3 # Level to run ( 1 = 11e2, 2 = 11e3, 3 = 11e4, 4 = 43e4, 5+ = 11e5 )

import os
import random
import subprocess
import time
import urllib.request

#reports factors to factordb
def send2db(composite, factors):
  factorline = str(factors)
  sendline = 'report=' + str(composite) + '%3D' + factorline
  dbcall = sendline.encode('utf-8')
  temp2 = urllib.request.urlopen('http://factordb.com/report.php', dbcall)

#processes factorT to see if factors were returned from GMP-ECM
def factorStr(factorT):
  factors = str(factorT)
  ind = factors.rfind("stdout")
  ind += 9
  factors = factors[ind:]
  factors = factors[:-4]
  return factors

print("Starting the factoring of", compNum, "composites. . .\n")

#main loop
foundf = 0
for x in range(compNum):
  randnum = random.randrange(ranNum) + offset
#fetch a number from factordb
  dbcall = 'http://factordb.com/listtype.php?t=3&mindig=' + str(compSize) + '&perpage=1&start=' + str(randnum) + '&download=1'
#some file processing to get the number into a format usable by GMP-ECM
  temp0 = urllib.request.urlopen(dbcall)
  temp1 = temp0.read()
  composite = temp1.decode(encoding='UTF-8')
  composite = composite.strip("\n")
  fstart = time.time()
#print number being worked on
  print("Composite", x + 1, "is:", composite)
  factorT = subprocess.run(['ecm', '-q', '-c', '100', '11e2'], stdout=subprocess.PIPE, input=temp1)
  factors = factorStr(factorT)
  if (len(factors) == len(composite)) and level > 1:
#    print("No factors found at 11e2! Trying 11e3. . .")
    factorT = subprocess.run(['ecm', '-c', '100', '-q', '11e3'], stdout=subprocess.PIPE, input=temp1)
    factors = factorStr(factorT)
  if (len(factors) == len(composite)) and level > 2:
    print("No factors found at 11e3! Trying 11e4. . .")
    factorT = subprocess.run(['ecm', '-c', '200', '-q', '11e4'], stdout=subprocess.PIPE, input=temp1)
    factors = factorStr(factorT)
  if (len(factors) == len(composite)) and level > 3:
    print("No factors found at 11e4! Trying 43e4. . .")
    factorT = subprocess.run(['ecm', '-q', '43e4'], stdout=subprocess.PIPE, input=temp1)
    factors = factorStr(factorT)
  if (len(factors) == len(composite)) and level > 4:
    print("No factors found at 43e4! Trying 11e5. . .")
    factorT = subprocess.run(['ecm', '-q', '11e5'], stdout=subprocess.PIPE, input=temp1)
    factors = factorStr(factorT)
  if (len(factors) > len(composite)):
    foundf += 1
    factors = factors.replace(' ','*')
    send2db(composite, factors)
    print("Factors for", x + 1, ":", factors)
  else:
    print("No factors found!")
  runtime = time.time() - fstart
  print("Elapsed time was", int(runtime / 60), "minute(s) and", int(runtime % 60), "second(s).  So far,", foundf, "of", x + 1, "(", int((foundf * 100) / (x + 1)), "%) have been factored.\n")
print("All", compNum, "composites completed.")
On a totally different tack, if you have a GMail account and would like to run a Colab session in the cloud, I have some examples of how to do that in my blog area. Do note, that if you overdo the use of the Colab resources by trying to run for long periods, the session will probably become limited for your account.
EdH is offline   Reply With Quote
Old 2020-01-20, 08:32   #1612
MDaniello
 
MDaniello's Avatar
 
May 2019
Rome, Italy

3·11 Posts
Default

Thanks for the suggestions! I'll look into YAFU and Colab.
MDaniello is offline   Reply With Quote
Old 2020-01-21, 18:15   #1613
wpolly
 
wpolly's Avatar
 
Sep 2002
Vienna, Austria

3×73 Posts
Default

In the same vein, a simple batch-ECM shell script:


Code:
# usage: auto_ecm.sh <digits> <no of composites> <offset> <B1> <no of curves>
wget -O c.inp "http://factordb.com/listtype.php?t=3&mindig=$1&perpage=$2&start=$3&download=1"
sed -i 's/ /\n/g' c.inp
./ecm -q -c $5 -inp c.inp $4 > c.out
paste -d '=' c.inp c.out > c.result
sed -i 's/ /\*/g' c.result
grep -e "\*" c.result > c.upload
rm c.inp
rm c.out
rm c.result
curl -POST -F format=7 -F "report=<c.upload" http://factordb.com/report.php
wpolly is offline   Reply With Quote
Old 2020-01-22, 04:55   #1614
SethTro
 
SethTro's Avatar
 
"Seth"
Apr 2019

181 Posts
Default

Quote:
Originally Posted by wpolly View Post
Indeed. The last post of Syd on this forum dates back to more than two years ago. The database in its current form really looks like an old and rusty machine without maintenance.


Anyway, here are some changes that I would like to see happen (and I'd like to volunteer to implement some of them):
Is Syd responding on other platforms?

I'd love to expand ECM reporting to allow for other sigma/parameterization (which I've already coded up)
SethTro is offline   Reply With Quote
Old 2020-01-23, 08:03   #1615
unconnected
 
unconnected's Avatar
 
May 2009
Russia, Moscow

22·33·23 Posts
Default

FYI: I've factored with ecm ~15000 C83's out of 33000.
unconnected is online now   Reply With Quote
Old 2020-01-23, 14:25   #1616
EdH
 
EdH's Avatar
 
"Ed Hall"
Dec 2009
Adirondack Mtns

7×13×37 Posts
Default

Quote:
Originally Posted by unconnected View Post
FYI: I've factored with ecm ~15000 C83's out of 33000.
I'm running over 50% success (ECM through 11e4) in all the range from higher 83 through 90 dd using the code I posted earlier. Here are the results from an i7 laptop (4 cores) for a run I did yesterday:
Code:
So far, 292 of 500 ( 58 %) have been factored.
So far, 282 of 500 ( 56 %) have been factored.
So far, 285 of 500 ( 57 %) have been factored.
So far, 284 of 500 ( 56 %) have been factored.
EdH is offline   Reply With Quote
Old 2020-01-23, 22:54   #1617
MisterBitcoin
 
MisterBitcoin's Avatar
 
"Nuri, the dragon :P"
Jul 2016
Good old Germany

2E116 Posts
Default

Quote:
Originally Posted by unconnected View Post
FYI: I've factored with ecm ~15000 C83's out of 33000.

Sweet!
Last 21 hours 841 out of 955 numbers needed SIQS. So, you might still be lucky with ecm while i crack the others with SIQS. :)
MisterBitcoin is offline   Reply With Quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
Database for k-b-b's: 3.14159 Miscellaneous Math 325 2016-04-09 17:45
Factoring database issues Mini-Geek Factoring 5 2009-07-01 11:51
database.zip HiddenWarrior Data 1 2004-03-29 03:53
Database layout Prime95 PrimeNet 1 2003-01-18 00:49
Is there a performance database? Joe O Lounge 35 2002-09-06 20:19

All times are UTC. The time now is 21:29.

Mon Oct 19 21:29:23 UTC 2020 up 39 days, 18:40, 1 user, load averages: 2.06, 2.24, 2.08

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.

This forum has received and complied with 0 (zero) government requests for information.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.
A copy of the license is included in the FAQ.