enrico icon indicating copy to clipboard operation
enrico copied to clipboard

issue with enrico_lc

Open astrolog1986 opened this issue 8 years ago • 2 comments

Hi, When I try to make the light curve with the time bins defined in a .txt file it gives wrong results (very high TS and high flux). I inserted the text file in the time section of config file [time] tmin = 0 tmax = 0 file = "/home/......" type = 'MET' and the text file contains time bins like this: 239557417.0 251328324.953
251328324.953 265886740.06
265886740.06 269919397.995
269919397.995 284028738.702
284028738.702 296878068.914 .......................... when it is finished, the TS in each bin is very high, at least first few bins are ok but then the results are very high (even the flux). Can you please help me to solve this problem.

Thank you in advance

astrolog1986 avatar Jun 26 '16 16:06 astrolog1986

Hi

did you try to put tmin = 251328324.953 and tmax = 296878068.914

you say

when it is finished, the TS in each bin is very high, at least first few bins are ok but then the results are very high (even the flux).

I am no sure if this is a problem or not. the source ca be variable

cheers

davidsanchez avatar Jun 30 '16 06:06 davidsanchez

hello,

I am also an error at time of lightcurve plotting with the help of matplotlib. The error is given below:

No Npred Plot produced /home/avijit/enrico/enrico/lightcurve.py:403: UserWarning: FixedFormatter should only be used together with FixedLocator ax.set_yticklabels([float(round(k,5)) for k in ax.get_yticks()10*(-offset_factor)]) WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Font family ['serif'] not found. Falling back to DejaVu Sans. WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern WARNING:matplotlib.font_manager:findfont: Generic family 'serif' not found because none of the following families were found: Computer Modern Traceback (most recent call last): File "/home/avijit/enrico/bin/enrico_plot_lc", line 21, in liste = np.genfromtxt(sys.argv[1],dtype="str",unpack=True) File "/home/avijit/anaconda3/envs/fermi/lib/python3.9/site-packages/numpy/lib/npyio.py", line 2266, in genfromtxt raise ValueError(errmsg) ValueError: Some errors were detected ! Line #9 (got 1 columns instead of 3) Line #20 (got 1 columns instead of 3) Line #29 (got 1 columns instead of 3) Line #37 (got 1 columns instead of 3) Line #43 (got 1 columns instead of 3) Line #49 (got 1 columns instead of 3) Line #54 (got 1 columns instead of 3) Line #70 (got 1 columns instead of 3) Line #79 (got 1 columns instead of 3) Line #85 (got 1 columns instead of 3) Line #101 (got 1 columns instead of 3) Line #115 (got 1 columns instead of 3) Line #127 (got 1 columns instead of 3) Line #147 (got 1 columns instead of 3) Line #163 (got 1 columns instead of 3) Line #171 (got 1 columns instead of 3) Line #186 (got 1 columns instead of 3) Line #200 (got 1 columns instead of 3) Line #211 (got 1 columns instead of 3) Line #217 (got 1 columns instead of 3) Line #227 (got 1 columns instead of 3) Line #231 (got 1 columns instead of 3) Line #245 (got 1 columns instead of 3)

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/home/avijit/enrico/bin/enrico_plot_lc", line 30, in lcobject.PlotLC() File "/home/avijit/enrico/enrico/lightcurve.py", line 243, in PlotLC self._PlotLC() File "/home/avijit/enrico/enrico/lightcurve.py", line 414, in _PlotLC plt.savefig(LcOutPath+"_TS.png", dpi=150, facecolor='w', edgecolor='w', File "/home/avijit/anaconda3/envs/fermi/lib/python3.9/site-packages/matplotlib/pyplot.py", line 944, in savefig res = fig.savefig(*args, **kwargs) File "/home/avijit/anaconda3/envs/fermi/lib/python3.9/site-packages/matplotlib/figure.py", line 3277, in savefig self.canvas.print_figure(fname, **kwargs) File "/home/avijit/anaconda3/envs/fermi/lib/python3.9/site-packages/matplotlib/backend_bases.py", line 2338, in print_figure result = print_method( File "/home/avijit/anaconda3/envs/fermi/lib/python3.9/site-packages/matplotlib/backend_bases.py", line 2204, in print_method = functools.wraps(meth)(lambda *args, **kwargs: meth( File "/home/avijit/anaconda3/envs/fermi/lib/python3.9/site-packages/matplotlib/_api/deprecation.py", line 385, in wrapper arguments = signature.bind(*inner_args, **inner_kwargs).arguments File "/home/avijit/anaconda3/envs/fermi/lib/python3.9/inspect.py", line 3045, in bind return self._bind(args, kwargs) File "/home/avijit/anaconda3/envs/fermi/lib/python3.9/inspect.py", line 3034, in _bind raise TypeError( TypeError: got an unexpected keyword argument 'papertype'

Help to solve this problem.

AstroAvijit avatar Oct 21 '22 09:10 AstroAvijit