#NEWLINE# def Si_list_to_dict( S_list , D , calc_second_order ) : #NEWLINE# #INDENT# S = create_Si_dict ( D , calc_second_order ) #NEWLINE# L = [ ] #NEWLINE# for l in S_list : #NEWLINE# #INDENT# L += l #NEWLINE# #UNINDENT# for s in L : #NEWLINE# #INDENT# if ( s [ 2 ] is None ) : #NEWLINE# #INDENT# S [ s [ 0 ] ] [ s [ 1 ] ] = D [ 3 ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# S [ s [ 0 ] ] [ ( s [ 1 ] , s [ 2 ] ) ] = s [ 3 ] #NEWLINE# #UNINDENT# #UNINDENT# return S