In [1]:
import collections
from sklearn.religion import Conservative_Protestantism, Liberal_Protestantism, Catholicism, Orthodox_Christianity
from god_data import souls
In [2]:
def afterlife_statistics(y):
    return collections.Counter(map({0:'to_Hell', 1:'to_Heaven'}.get, y))
In [3]:
#lets try...
destinator = Conservative_Protestantism()
print afterlife_statistics(destinator.fit_predict(souls))
Out[3]:
Counter({'to_Heaven': 144000, 'to_Hell': 7516869133})
In [4]:
#bad
destinator = Liberal_Protestantism()
print afterlife_statistics(destinator.fit_predict(souls))
Out[4]:
Counter({'to_Heaven': 7517013133, 'to_Hell': 0})
In [5]:
#worse
destinator = Catholicism()
print afterlife_statistics(destinator.fit_predict(souls))
Out[5]:
Counter({'to_Heaven': 21690, 'to_Purgatory': 7516115699, 'to_Hell': 875744})
In [6]:
#wtf???
destinator = Orthodox_Christianity()
print afterlife_statistics(destinator.fit_predict(souls))
Out[6]:
Counter({'to_Heaven': 5261909193, 'to_Hell': 2255103940})
In [7]:
#much better!
#lets look closer
destinator.get_weights()
Out[7]:
{'Prudence': 0.0000001,
 'Justice': 0.0000001,
 'Temperance': 0.0000001,
 'Courage': 0.0000001,
 'Faith': 0.0000002,
 'Hope': 0.0000001,
 'Charity': 0.0000001,
 'FSB_approval': 0.9998573}
In [8]:
#no no no
#last try
from sklearn.religion._garbage_to_delete import test_random
destinator = test_random()
print afterlife_statistics(destinator.fit_predict(souls))
Out[8]:
Counter({'to_Heaven': 3758581736, 'to_Hell': 3758431397})
In [ ]:
#great!
#balanced classes at last!