Commits

Ville Suoranta authored 320ea757542 Merge
Pull request #778: CAS-14093

Merge in CASA/casa6 from CAS-14093 to master * commit '19913d87ffc730f6fa3dc4b4f9f32a663004e698': (37 commits) Update build.conf versions casaplotserver 1.8.1, casaplotms 2.4.1, casalogger 1.0.18, casafeather 0.0.21, casatablebrowser 0.0.34 Update plotms in build.conf Fix build.conf plotms Update plotserver version Update build.conf to dev versions Update PlotMS in build.conf to 2.3.4a14231.dev6 Trigger a build Compare float values with tolerances rather than exact values. Restore casaviewer in build.conf Restore almatasks in build.conf Add build.conf with arm packages Remove failed arch attempts Revert "Revert "Test -arch arm64"" Revert "Revert "Try arm64 as a swig compile option"" Revert "Allow single element Java version number" Revert "Add defition CMAKE_OSX_ARCHITECTURES=arm64" Revert "Try running Java with arch -arm64" Revert "Fix previous commit" Revert "Fix mod-closure" Fix mod-closure ...

casa5/gcwrap/python/scripts/flaghelper.py

Modified
2091 2091 Cast it to the corresponding Python type
2092 2092 and return the casted value'''
2093 2093
2094 2094 import numpy as np
2095 2095
2096 2096 val = None
2097 2097
2098 2098 if(isinstance(elem,np.int) or isinstance(elem,np.int8) or
2099 2099 isinstance(elem,np.int16) or isinstance(elem,np.int32) or
2100 2100 isinstance(elem,np.int64)):
2101 - val = int(elem)
2101 + val = int(elem)
2102 2102
2103 2103 elif(isinstance(elem,np.float) or isinstance(elem,np.float16) or
2104 - isinstance(elem,np.float32) or isinstance(elem,np.float64) or
2105 - isinstance(elem,np.float128)):
2106 - val = float(elem)
2107 -
2104 + isinstance(elem,np.float32) or isinstance(elem,np.float64)):
2105 + val = float(elem)
2106 +
2107 + # float128 is not available on all platforms
2108 + elif (hasattr(np, "float128")) and isinstance(elem,np.float128):
2109 + val = float(elem)
2110 +
2108 2111 elif(isinstance(elem,np.double)):
2109 2112 val = float(elem)
2110 2113
2111 2114 else:
2112 2115 # it is none of the above numpy types
2113 2116 val = elem
2114 2117
2115 2118 # return the casted element
2116 2119 return val
2117 2120

Everything looks good. We'll let you know here if there's anything you should know about.

Add shortcut