Open samoylv opened 7 years ago
Could you please provide simple test to reproduce this error?
On Tue, Oct 18, 2016 at 1:02 PM, samoylv notifications@github.com wrote:
calculation CRL with dispersion under Py 2.7
this line https://github.com/samoylv/WPG/blob/feature/srw_update/wpg/srwlib.py#L2836 brings TypeError: only length-1 arrays can be converted to Python scalars
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/samoylv/WPG/issues/92, or mute the thread https://github.com/notifications/unsubscribe-auth/AA6Pt1Y2qvBafkdNXHpTPBFcJWdtee6Pks5q1JkpgaJpZM4KZmV4 .
tutorial3_beamline_focusing_CRL_disp.ipynb, running on Py 2.7 in cell 12
BTW, numpy.exp() in srwlib.py does not help
We should pass parameters for srwl_opt_setup_CRL as list
crl_delta = list(be_data[:,1]) # Dummy numbers)
crl_attenuation_length = list(be_data[:,2]) #Dummy numbers)
May be we should check it in our wrapper createCRL....
good point. it was also fix from @CFGrote #80 - is that the same issue?
@buzmakov fixed?
calculation CRL with dispersion under Py 2.7
this line brings TypeError: only length-1 arrays can be converted to Python scalars