#NEWLINE# def kl_mc( self , other , size = 500000 ) : #NEWLINE# #INDENT# fun = ( lambda x : ( self . logpdf ( x ) - other . logpdf ( x ) ) ) #NEWLINE# rvs = self . rvs ( size = other ) #NEWLINE# return fun ( rvs ) . mean ( )