Ejemplo n.º 1
0
def run8():
	measure=("extent")
	seed = randint(0,1000000)
	rf = randomFact(NumberFact, measure, rseed=seed)
	magnitude = rf.magnitude
	scale = rf.scale
#	print(rf.render)
#	test = NumberFact.objects.filter().order_by("value")[0:10]#
#	for item in test:
#		print(item.render, item.magnitude, item.value)

#	print(bracketNumber(NumberFact, "481", 3, "extent"))
#	for i in range(-3,24,3):
#		print(i, bracketNumber(NumberFact, "1.25", i, measure))
#		print(i+1,bracketNumber(NumberFact, "12.5", i, measure))
#		print(i+2,bracketNumber(NumberFact, "125", i, measure))

#	for i in range(-3,24,3):
#		print(i, bracketNumber(NumberFact, "1.0", i, measure))
#		print(i+1,bracketNumber(NumberFact, "10.0", i, measure))
#		print(i+2,bracketNumber(NumberFact, "100.0", i, measure))

	for i in range(-3,18,3):
		print(i, bracketNumber(NumberFact, "1.0", i, measure))
		print(i,bracketNumber(NumberFact, "2.0", i, measure))
		print(i,bracketNumber(NumberFact, "4.0", i, measure))
		print(i,bracketNumber(NumberFact, "8.0", i, measure))
		print(i,bracketNumber(NumberFact, "16.0", i, measure))
		print(i,bracketNumber(NumberFact, "32.0", i, measure))
		print(i,bracketNumber(NumberFact, "64.0", i, measure))
		print(i,bracketNumber(NumberFact, "125.0", i, measure))
		print(i,bracketNumber(NumberFact, "250.0", i, measure))
		print(i,bracketNumber(NumberFact, "500.0", i, measure))
Ejemplo n.º 2
0
def run():
    measure = ("extent")
    seed = randint(0, 1000000)
    rf = randomFact(NumberFact, measure, rseed=seed)
    magnitude = rf.magnitude
    scale = rf.scale
    #	print(rf.render)
    #	test = NumberFact.objects.filter().order_by("value")[0:10]#
    #	for item in test:
    #		print(item.render, item.magnitude, item.value)

    #	print(bracketNumber(NumberFact, "481", 3, "extent"))
    #	for i in range(-3,24,3):
    #		print(i, bracketNumber(NumberFact, "1.25", i, measure))
    #		print(i+1,bracketNumber(NumberFact, "12.5", i, measure))
    #		print(i+2,bracketNumber(NumberFact, "125", i, measure))

    #	for i in range(-3,24,3):
    #		print(i, bracketNumber(NumberFact, "1.0", i, measure))
    #		print(i+1,bracketNumber(NumberFact, "10.0", i, measure))
    #		print(i+2,bracketNumber(NumberFact, "100.0", i, measure))

    for i in range(-3, 18, 3):
        print(i, bracketNumber(NumberFact, "1.0", i, measure))
        print(i, bracketNumber(NumberFact, "2.0", i, measure))
        print(i, bracketNumber(NumberFact, "4.0", i, measure))
        print(i, bracketNumber(NumberFact, "8.0", i, measure))
        print(i, bracketNumber(NumberFact, "16.0", i, measure))
        print(i, bracketNumber(NumberFact, "32.0", i, measure))
        print(i, bracketNumber(NumberFact, "64.0", i, measure))
        print(i, bracketNumber(NumberFact, "125.0", i, measure))
        print(i, bracketNumber(NumberFact, "250.0", i, measure))
        print(i, bracketNumber(NumberFact, "500.0", i, measure))
Ejemplo n.º 3
0
def run12():
	klass = NumberFact
	measure=("extent")
	seed = randint(0,1000000)
	rf = randomFact(NumberFact, measure, rseed=seed)
	print(rf.render)
	print(rf.measure)
	facts = neatFacts(klass, rf)
	for fact in facts:
#		print(fact["comparison"], fact["fact2"].render2)
		print(fact)
		print(fact["fact2"].measure)
Ejemplo n.º 4
0
def run12():
    klass = NumberFact
    measure = ("extent")
    seed = randint(0, 1000000)
    rf = randomFact(NumberFact, measure, rseed=seed)
    print(rf.render)
    print(rf.measure)
    facts = neatFacts(klass, rf)
    for fact in facts:
        #		print(fact["comparison"], fact["fact2"].render2)
        print(fact)
        print(fact["fact2"].measure)
Ejemplo n.º 5
0
def run7():
	measure=("area")
	seed = randint(0,1000000)
	rf = randomFact(NumberFact, measure, rseed=seed)
	print(rf.render)

	bestComparisons, tolerance, score  = numberFactsLikeThis(NumberFact, rf, rseed=seed) 

	print(tolerance, score)
	for fact in bestComparisons:
		print(fact.render_folk)
		print(fact.magnitude)
		print(fact.scale)
		print(fact.permlink)

	biggest = biggestNumberFact(bestComparisons)
	print(">>>", biggest.render)
Ejemplo n.º 6
0
def run7():
    measure = ("extent")
    seed = randint(0, 1000000)
    rf = randomFact(NumberFact, measure, rseed=seed)
    print(rf.render)

    bestComparisons, tolerance, score = numberFactsLikeThis(NumberFact,
                                                            rf,
                                                            rseed=seed)

    print(tolerance, score)
    for fact in bestComparisons:
        print(fact.render)
        print(fact.magnitude)
        print(fact.scale)

    biggest = biggestNumberFact(bestComparisons)
    print(">>>", biggest.render)
Ejemplo n.º 7
0
def run13():
	klass = NumberFact
	measure=("extent")
	seed = randint(0,1000000)
	rf = randomFact(NumberFact, measure, rseed=seed)
	print(rf.render_folk)
Ejemplo n.º 8
0
def run13():
    klass = NumberFact
    measure = ("extent")
    seed = randint(0, 1000000)
    rf = randomFact(NumberFact, measure, rseed=seed)
    print(rf.render_folk)