vtsuperdarn / davitpy

DEPRECATED The DaViT Python project
http://vtsuperdarn.github.com/davitpy/
GNU General Public License v3.0
37 stars 59 forks source link

ImportError when trying to make RTI plot #263

Closed ndestefano closed 8 years ago

ndestefano commented 8 years ago

Hello,

I am trying to reproduce the MUSIC notebook (https://github.com/vtsuperdarn/davitpy/blob/master/docs/notebook/MUSIC.ipynb). I can successfully load the file and see that there is fit data in there (input 4 of the notebook). However when I try to make the RTI figure (input 8) I get the following error:

---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
<ipython-input-4-5fe316e7ade9> in <module>()
----> 1 fit = pydarn.plotting.musicRTI(dataObj)

/usr/local/lib/python2.7/site-packages/davitpy-0.5-py2.7-macosx-10.11-x86_64.egg/davitpy/pydarn/plotting/musicPlot.pyc in __init__(self, dataObject, dataSet, beam, coords, xlim, ylim, axis, scale, plotZeros, max_sounding_time, xBoundaryLimits, yBoundaryLimits, yticks, ytick_lat_format, autoScale, plotTerminator, axvlines, axvline_color, secondary_coords, plot_info, plot_title, plot_range_limits_label, cmap_handling, cmap, bounds, norm, plot_cbar, cbar_ticks, cbar_shrink, cbar_fraction, cbar_gstext_offset, cbar_gstext_fontsize, model_text_size, y_labelpad, **kwArgs)
    555 
    556         from scipy import stats
--> 557         from rti import plotFreq,plotNoise
    558 
    559         if axis is None:

ImportError: cannot import name plotFreq

When I look for the function plotFreq I do not find it in rti.py. In fact, I searched the entire repository and I don't see it. There is a plot_freq function in rti but it has a different parameter list. Do I have some sort of dependency that's missing?

w2naf commented 8 years ago

Hi there. No, you are not missing anything... Something broke when were trying to do a large davitpy update.

I'll try to patch it later today and get back to you.

Best, Nathaniel On Jul 8, 2016 9:08 AM, "ndestefano" notifications@github.com wrote:

Hello,

I am trying to reproduce the MUSIC notebook ( https://github.com/vtsuperdarn/davitpy/blob/master/docs/notebook/MUSIC.ipynb). I can successfully load the file and see that there is fit data in there (input 4 of the notebook). However when I try to make the RTI figure (input 8) I get the following error:


ImportError Traceback (most recent call last)

in () ----> 1 fit = pydarn.plotting.musicRTI(dataObj) /usr/local/lib/python2.7/site-packages/davitpy-0.5-py2.7-macosx-10.11-x86_64.egg/davitpy/pydarn/plotting/musicPlot.pyc in **init**(self, dataObject, dataSet, beam, coords, xlim, ylim, axis, scale, plotZeros, max_sounding_time, xBoundaryLimits, yBoundaryLimits, yticks, ytick_lat_format, autoScale, plotTerminator, axvlines, axvline_color, secondary_coords, plot_info, plot_title, plot_range_limits_label, cmap_handling, cmap, bounds, norm, plot_cbar, cbar_ticks, cbar_shrink, cbar_fraction, cbar_gstext_offset, cbar_gstext_fontsize, model_text_size, y_labelpad, **kwArgs) 555 556 from scipy import stats --> 557 from rti import plotFreq,plotNoise 558 559 if axis is None: ImportError: cannot import name plotFreq When I look for the function plotFreq I do not find it in rti.py. In fact, I searched the entire repository and I don't see it. There is a plot_freq function in rti but it has a different parameter list. Do I have some sort of dependency that's missing? — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/vtsuperdarn/davitpy/issues/263, or mute the thread https://github.com/notifications/unsubscribe/ABvxDtMvLMcxDpXJ0t_QkvRznpYHGBj8ks5qTkuwgaJpZM4JIA7H .
w2naf commented 8 years ago

Hi, @ndestefano . https://github.com/vtsuperdarn/davitpy/pull/265 will fix your problem.

Give it a try and let me know. Thanks!

ndestefano commented 8 years ago

That seemed to work, thanks!