This archive contains answers to questions sent to Unidata support through mid-2025. Note that the archive is no longer being updated. We provide the archive for reference; many of the answers presented here remain technically correct, even if somewhat outdated. For the most up-to-date information on the use of NSF Unidata software and data services, please consult the Software Documentation first.
> Full Name: JP Kalb > Email Address: address@hidden > Organization: SJSU > Package Version: 5.0u1 build date:2014-08-08 16:54 UTC > Operating System: Windows 7 > Hardware: Java: home: C:\Users\metr166\IDV_5.0u1\jre version: 1.7.0_51 > j3d:1.6.0-pre9-daily-experimental daily > Description of problem: Creating display: Contour Plan View > Unknown return value type:org.python.core.PySingleton > Value=Error > Code:haines(t950,t850,d850) > I got this error using this code > t95=make2D(noUnit(t950)) > t85=make2D(noUnit(t850)) > d85=make2D(noUnit(d850)) > deltat=t95-t85 > dpp=t85-d85 > if deltat<4: > s=1 > elif 4<=deltat<8: > s=2 > else: > s=3 > if dpp<6: > m=1 > elif 6<=dpp<10: > m=2 > else: > m=3 > h=m+s > return h > what is the problem with this code? > The IDV can only take VisAD type in its formula return, and the variable h is not a valid type. We do have workshop here for you to learn more in depth knowledge. Yuan > ****************** > Stack trace: > java.lang.IllegalArgumentException: Unknown return value > type:org.python.core.PySingleton > Value=Error > Code:haines(t950,t850,d850) > at ucar.unidata.data.DerivedDataChoice.getData(DerivedDataChoice.java:821) > at ucar.unidata.data.DataChoice.getData(DataChoice.java:637) > at ucar.unidata.data.DataInstance.getData(DataInstance.java:243) > at ucar.unidata.data.DataInstance.getData(DataInstance.java:207) > at ucar.unidata.data.grid.GridDataInstance.init(GridDataInstance.java:206) > at ucar.unidata.data.grid.GridDataInstance.<init>(GridDataInstance.java:163) > at ucar.unidata.data.grid.GridDataInstance.<init>(GridDataInstance.java:144) > at > ucar.unidata.idv.control.GridDisplayControl.doMakeDataInstance(GridDisplayControl.java:299) > at > ucar.unidata.idv.control.DisplayControlImpl.initializeDataInstance(DisplayControlImpl.java:3278) > at > ucar.unidata.idv.control.DisplayControlImpl.setData(DisplayControlImpl.java:3234) > at ucar.unidata.idv.control.PlanViewControl.setData(PlanViewControl.java:664) > at > ucar.unidata.idv.control.ContourPlanViewControl.setData(ContourPlanViewControl.java:195) > at ucar.unidata.idv.control.PlanViewControl.init(PlanViewControl.java:489) > at > ucar.unidata.idv.control.DisplayControlImpl.init(DisplayControlImpl.java:1402) > at > ucar.unidata.idv.control.DisplayControlImpl.init(DisplayControlImpl.java:1085) > at ucar.unidata.idv.ControlDescriptor.initControl(ControlDescriptor.java:986) > at ucar.unidata.idv.ControlDescriptor$1.run(ControlDescriptor.java:911) > at ucar.unidata.util.Misc$3.run(Misc.java:1243) > > > Ticket Details =================== Ticket ID: JMH-197775 Department: Support IDV Priority: Normal Status: Closed