Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Very low accuracy for small interval #7

Closed
pagenum opened this issue Jan 7, 2022 · 2 comments
Closed

Very low accuracy for small interval #7

pagenum opened this issue Jan 7, 2022 · 2 comments

Comments

@pagenum
Copy link

pagenum commented Jan 7, 2022

import random, time
from randcrack import RandCrack

random.seed(10)

rc = RandCrack()

for i in range(624):
	rc.submit(random.randrange(0,5))
	# Could be filled with random.randint(0,4294967294) or random.randrange(0,4294967294)

for i in range(20):
	print("Random result: {}\nCracker result: {}".format(random.randrange(0,5), rc.predict_randrange(0,5)))


Random result: 4
Cracker result: 2
Random result: 4
Cracker result: 4
Random result: 0
Cracker result: 2
Random result: 3
Cracker result: 0
Random result: 2
Cracker result: 0
Random result: 3
Cracker result: 4
Random result: 1
Cracker result: 0
Random result: 0
Cracker result: 0
Random result: 3
Cracker result: 0
Random result: 3
Cracker result: 0
Random result: 0
Cracker result: 4
Random result: 0
Cracker result: 2
Random result: 3
Cracker result: 0
Random result: 1
Cracker result: 0
Random result: 0
Cracker result: 0
Random result: 3
Cracker result: 0
Random result: 4
Cracker result: 4
Random result: 0
Cracker result: 0
Random result: 0
Cracker result: 4
Random result: 4
Cracker result: 2
Press any key to continue . . .

Only 25% accuracy.

@tna0y
Copy link
Owner

tna0y commented Jan 15, 2022

Please try randcrack from the master branch of thip repository. The fix has not been uploaded to the PyPI yet.

@tna0y
Copy link
Owner

tna0y commented Jun 24, 2022

The fix has been uploaded to PyPI in version 0.2.0.

@tna0y tna0y closed this as completed Jun 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants