#NEWLINE# def __call__( self , pop ) : #NEWLINE# #INDENT# idx = np . argsort ( pop . values ) #NEWLINE# credit = np . zeros ( pop . K ) #NEWLINE# for i in range ( pop . K ) : #NEWLINE# #INDENT# credit [ idx [ i ] ] = ( i / ( pop . K - 1.0 ) ) #NEWLINE# #UNINDENT# return credit