CDAT / cdat

Community Data Analysis Tools
Other
174 stars 68 forks source link

PlotProperties getting QPromptCellWidget instead of cell widget #1181

Open remram44 opened 9 years ago

remram44 commented 9 years ago

From UV-CDAT/VisTrails#30

It seems that PlotProperties is updated from ProjectController#update_workflow() just after execute_plot() and this is not safe. The PlotProperties gets the QPromptCellWidget instead of the new cell widget.

A workaround can be added for 2.2 but this should definitely be fixed later.

doutriaux1 commented 9 years ago

@remram44 actually the work around doesn't really work when I apply it (https://github.com/UV-CDAT/VisTrails/pull/30) it does not break anymore, but doesn't seem to produce any plot any longer. @vvpalav or @hgohil2805 can you take a look please?

hgohil2805 commented 9 years ago

@remram44 This is caused by the cell not being deleted correctly and because of the changes that we made last week of setting it to none in the delete later method. I had encountered similar exception with the changes that I had shown you before and I had used a catch all which worked fine (not sure if you remember the changes).

Until we find the the object which is keeping the reference to the cell and remove it while deleting, I feel keeping a catch all should be fine as incorrect cell removal should probably be the only thing which causes the exception to be thrown .

doutriaux1 commented 9 years ago

@hgohil2805 not sure the catch all is actually working in this case, it does prevent it form failing, but nothing gets drawn in the spreadsheet. Now that might be something else that prevents the plot from appearing I'm not positive.

remram44 commented 9 years ago

@hgohil2805 I have no idea what you're talking about and disagree on all points.

remram44 commented 9 years ago

@doutriaux1 I don't run into the issue, with either workaround or none at all. What system are you using? The patch in UV-CDAT/VisTrails#30 should prevent the traceback you gave from happening; it might interfere with the the PlotProperties, but really can't prevent plotting.

doutriaux1 commented 9 years ago

It's very hard to reproduce. Has to come from diagnostics and taor diagrmasn. Ask @mcenerney1 or @painter1 for steps and location of data. Because I can't reproduce with uvcmetrics test data. I need @mcenerney1 special data.

mcenerney1 commented 9 years ago

I really need help on this one and I'll help out in any way possible. On aims1 in my area (mcenerney1) there are two files cam35_data.tar (model data) and taylor_obs_data.tar (observation data). You'll need to download them to reproduce the issue. Documentation on running the AMWG diagnostics from the gui can be found at http://uvcdat-dev.llnl.gov/documentation/diagnostics/diagnostics.html To run from the command line, you'll need uvcmetrics. In the directory uvcmetrics/src/python/frontend run
diags.py --model path=$HOME/uvcmetrics_test_data/cam35_data/,climos=yes \ --obs path=$HOME/uvcmetrics_test_data/obs_data/,filter='f_startswith("NCEP")',climos=yes \ --outputdir $HOME/Documents/Climatology/ClimateData/diagout/ --package AMWG --sets 14 \ --seasons JAN --plots yes --vars T --varopts '200 mbar'

Once again I'll do whatever it takes to get this resolved; email, phone calls, telepathy. Thanks Jim

doutriaux1 commented 9 years ago

@mcenerney1 they need instructions for gui I fixed command line already. @painter1 merged it. But gui needs my uvcdat pretty merged in and them your instructions so they can see the failure.

doutriaux1 commented 9 years ago

Again we don't know if the failure prevents plot or if something else in diagnosticsWidgets.py prevents it once we are pas the failure

mcenerney1 commented 9 years ago

To see the failure do the following. Assuming the data directories are in cam35_data and taylor_obs_data, bring up uvcdat. Under Diagnostics select AMWG. A new window comes up. Under Use Dataset 1, click Set Path and choose the cam35_data directory. Next select Use Observations 1. Set Path to taylor_obs_data. Make sure NCEP apears in the adjoining window. If not, select it in the menu. In the upper window that displays the complete list of diagnostics, select 14 - Taylor diagrams. Once done there is a section just below to set the variable options. In the Variables pull down menu, select T. In the seasons menu, select JAN. In the Variables Options menu, select "200 mbar". Now click Apply and off it goes. If you run into a snag, let me know.

mcenerney1 commented 9 years ago

Any progress on this issue? Are the instructions clear?

hgohil2805 commented 9 years ago

I'll try and reproduce the error right now. Will let you know if I find any solution or have any issues reproducing it.

mcenerney1 commented 9 years ago

Thanks!

mcenerney1 commented 9 years ago

I have 2 tar files, cam35_data and taylor_obs_data, in mcenerney1 on aims1.llnl.gov Do you have an account?

painter1 commented 9 years ago

If you have no account on aims1, what about rhea.ccs.ornl.gov or any other ORNL machine with Lustre mounted?

hgohil2805 commented 9 years ago

Nope, I don't have an account on any of them.

painter1 commented 9 years ago

NERSC, Argonne, any place other than NYU?

hgohil2805 commented 9 years ago

No. You guys are going to have to upload them someplace .

mcenerney1 commented 9 years ago

Can you get me an account at NYU?

painter1 commented 9 years ago

Jim, I think you can upload to ftp.llnl.gov and Hardik can download from there.

hgohil2805 commented 9 years ago

Nah, I don't think I can get you an NYU account :(

mcenerney1 commented 9 years ago

Jeff found a way to get you the files (Thanks!). We have a ftp site, here's how to get the files ftp ftp.llnl.gov username = anonymous password = your email Once you're login cd outgoing/mcenerney1 There are 2 files: cam35_data.tar and taylor_obs_data.tar get cam35_data.tar
and the same of taylor_obs_data.tar

hgohil2805 commented 9 years ago

Thank you guys.. I have the files. I have 12 .nc files in cam_35_data and around 15-16 files in taylor_obs_data. I am unable to load the dataset. As soon as I select the cam_35 directory, it pops up the following error. I figured something might be wrong with my build so I tried to use the same data files on a completely fresh build that I have on another VMware Ubuntu but it pops up the same error.

Here's the screen shot

error

Am I doing something wrong? If not, do you get the same error?

hgohil2805 commented 9 years ago

Sorry, I meant to ask if you get the error when you use the GUI..

mcenerney1 commented 9 years ago

Jeff Is this the wrong version of uvcmetrics in uvcdat is the wrong version?

painter1 commented 9 years ago

Hardik, haven't seen that. It surprises me. If self.opts is initialized as an Options object (options.py), then self.opts._opts==[] initially. And it is initialized as an Options object, see the beginning of the class definition of DiagnosticsDockWidget.

Jim, if you're asking whether this is about incompatible versions, I'd say you're probably right. At least, it must be some kind of a build issue.

mcenerney1 commented 9 years ago

I believe the solution is to get the latest uvcmetrics and build with it.

hgohil2805 commented 9 years ago

Jim, wouldn't that only help when you are running it from the command line?

painter1 commented 9 years ago

No, the GUI file diagnosticsDocWidget.py is just an interface to the diagnostics in uvcmetrics. In particular, options.py was changed a month or two ago. If you have the latest VisTrails (uvcdat-master), it requires a recent version of options.py.

mcenerney1 commented 9 years ago

Thanks, Jeff. I think I've seen this before.

hgohil2805 commented 9 years ago

Ah ok, let us know if it works with the latest uvcmetrics.

painter1 commented 9 years ago

You won't see your error message with the latest ucmetrics. Most things work. I think we're back to the original VisTrails issue here.

mcenerney1 commented 9 years ago

Hardik, can I do anything more to help you??

hgohil2805 commented 9 years ago

Jim, I am not sure what exactly the latest uvcmetrics will help you with. Will it help remove only the error that I have attached above on the screen shot or will it actually help you plot things correctly?

Jeff, I built the new uvcdat about 15 days ago using the files that were considered a good fit for 2.2. Should it not have the latest options.py file?

mcenerney1 commented 9 years ago

I think the version in uvcdat has a problem. The latest will only remove the error on your screen shot.

painter1 commented 9 years ago

The UV-CDAT distribution often comes with months-old copies of the diagnostics, aka metrics. I routinely wipe out the metrics installation there and install my own. In fact, that was necessary when I built a new UV-CDAT on March 25, about the same time as yours. So I'm sure that you need to delete whatever UV-CDAT has put into site-packages/metrics, and then go to the uvcmetrics source tree (devel branch) and type "python setup.py install". It's quick and easy.

hgohil2805 commented 9 years ago

Ok, Thanks Jim.

Jeff. I am going to try and install the new one. Will let you know if I face any issues. Also, I feel that if this is something that you normally always do and considering that we do require it to make sure that all the features correctly, then we need to work on some way to make sure that the latest distribution has the latest versions (if it is not already included).

doutriaux1 commented 9 years ago

@painter1 it is also worth noting that you guys are NOT using "master" but "devel" branch.

painter1 commented 9 years ago

The release versions of UV-CDAT do contain appropriate versions of the diagnostics - at least, they have so far. Probably development versions of UV-CDAT contain obsolete versions of the diagnostics because that dates to the previous release.

mcenerney1 commented 9 years ago

Hardik Were you able to get past the uvcmetrics issues?

hgohil2805 commented 9 years ago

Jim, I wasn't able to.

Jeff, Can you tell me where exactly I need to issue the python setup.py install command from?

hgohil2805 commented 9 years ago

Jim, The traceback given here by charles is the one you see right?https://github.com/UV-CDAT/VisTrails/pull/30

I can use that in the meanwhile to see if I can find something.

painter1 commented 9 years ago

Hardik, For running "python setup.py install", there are two things you need to get right:

  1. The right python: First install UV-CDAT. Then run its setup_runtime.sh or setup_runtime.csh.
  2. The right setup.py: cd to the root of the uvcmetrics directory tree. That has a file setup.py. Then run "python setup.py install".

And it is safer if, before running setup.py, you find the python's site-packages directory, and delete the contents of its metrics subdirectory.

mcenerney1 commented 9 years ago

I believe this is an issue. There may be others.

hgohil2805 commented 9 years ago

I believe this is the one? https://github.com/UV-CDAT/uvcmetrics/blob/master/setup.py

So because I had removed my build directory and I could not the file anywhere, I got the files from https://github.com/UV-CDAT/uvcmetrics and then ran setup.py , after removing the files from site-packages/metrics which put new files in its place . This however still gave me the same error that I had from the screen shot.

You think building entire uvcdat from master will help?

painter1 commented 9 years ago

Do not use the master branch of uvcmetrics. Use the devel branch. Make sure that you do a pull from the uvcmetrics project repository, devel branch. I don't have your directory structure, so I can't tell for sure what you're doing. Anyway, there's only one setup.py in uvcmetrics.

painter1 commented 9 years ago

Here's where to pull from: git@github.com:UV-CDAT/uvcmetrics.git And do a "git checkout devel". In uvcmetrics the master branch is rarely updated, usually at the same time as a UV-CDAT release.

hgohil2805 commented 9 years ago

Ok, will try that out.

mcenerney1 commented 9 years ago

Hardik Any luck with this issue?

hgohil2805 commented 9 years ago

Nope, not yet. I've got the new uvcmetrics (thanks you!) and I can load the files. Can you give me a data set that works correctly so that I can look at how the flow works.?