#NEWLINE# def compute_message_to_parent( self , parent , index , u_self , u_n , u_V ) : #NEWLINE# #INDENT# if ( index == 0 ) : #NEWLINE# #INDENT# raise NotImplementedError ( 'Message from Wishart to degrees of freedom parameter (first parent) not yet implemented' ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( u_self == 1 ) : #NEWLINE# #INDENT# Lambda = u_self [ 0 ] #NEWLINE# n = u_n [ 0 ] #NEWLINE# return [ ( ( - 0.5 ) * Lambda ) , ( 0.5 * n ) ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# raise ValueError ( 'Invalid parent index {0}' . format ( index ) )