#NEWLINE# def weighted_answer_probabilities( self , weight_with_targets = False , * args , **kwargs ) : #NEWLINE# #INDENT# answer_probabilities = self . answer_probabilities ( * args , ** kwargs ) #NEWLINE# ( q1 , q2 , q3 , q4 , q5 , q6 , q7 , q8 , q9 , q10 , q11 ) = answer_probabilities #NEWLINE# if weight_with_targets : #NEWLINE# #INDENT# ( t1 , t2 , t3 , t4 , t5 , t6 , t7 , t8 , t9 , t10 , t11 ) = self . targets ( * args , ** kwargs ) #NEWLINE# w1 = 1 #NEWLINE# w2 = t1 [ : , 1 ] #NEWLINE# w3 = t2 [ : , 1 ] #NEWLINE# w4 = w3 #NEWLINE# w7 = t1 [ : , 0 ] #NEWLINE# w9 = t2 [ : , 0 ] #NEWLINE# w10 = t4 [ : , 0 ] #NEWLINE# w11 = w10 #NEWLINE# w5 = w4 #NEWLINE# w6 = 1 #NEWLINE# w8 = t6 [ : , 0 ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# w1 = 1 #NEWLINE# w2 = q1 [ : , 1 ] #NEWLINE# w3 = ( q2 [ : , 1 ] * w2 ) #NEWLINE# w4 = w3 #NEWLINE# w7 = q1 [ : , 0 ] #NEWLINE# w9 = ( q2 [ : , 0 ] * w2 ) #NEWLINE# w10 = ( q4 [ : , 0 ] * w4 ) #NEWLINE# w11 = w10 #NEWLINE# w5 = w4 #NEWLINE# w6 = 1 #NEWLINE# w8 = ( q6 [ : , 0 ] * w6 ) #NEWLINE# #UNINDENT# wq1 = ( q1 * w1 ) #NEWLINE# wq2 = ( q2 * w2 . dimshuffle ( 0 , 'x' ) ) #NEWLINE# wq3 = ( q3 * w3 . dimshuffle ( 0 , 'x' ) ) #NEWLINE# wq4 = ( q4 * w4 . dimshuffle ( 0 , 'x' ) ) #NEWLINE# wq5 = ( q5 * w5 . dimshuffle ( 0 , 'x' ) ) #NEWLINE# wq6 = ( q6 * w6 ) #NEWLINE# wq7 = ( q7 * w7 . dimshuffle ( 0 , 'x' ) ) #NEWLINE# wq8 = ( q8 * w8 . dimshuffle ( 0 , 'x' ) ) #NEWLINE# wq9 = ( w4 * w9 . dimshuffle ( 0 , 'x' ) ) #NEWLINE# wq10 = ( q10 * w10 . dimshuffle ( 0 , 'x' ) ) #NEWLINE# wq11 = ( q11 * w11 . dimshuffle ( 0 , 'x' ) ) #NEWLINE# return ( wq1 , wq2 , wq3 , wq4 , wq5 , wq6 , wq7 , wq8 , wq9 , wq10 , wq11 )