Changeset 02c8c50 in flex_extract.git for python/GribTools.py
- Timestamp:
- Mar 18, 2018, 6:27:28 PM (6 years ago)
- Branches:
- master, ctbto, dev
- Children:
- efdb01a
- Parents:
- 64cf353
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
python/GribTools.py
r64cf353 r02c8c50 86 86 List of keynames. 87 87 88 wherekeynames: list of ??? 88 wherekeynames: list of ???, optional 89 89 Default value is an empty list. 90 90 91 wherekeyvalues: list of ??? 91 wherekeyvalues: list of ???, optional 92 92 Default value is an empty list. 93 93 … … 154 154 List of keynames. Default is an empty list. 155 155 156 wherekeynames: list of ??? 156 wherekeynames: list of ???, optional 157 157 Default value is an empty list. 158 158 159 wherekeyvalues: list of ??? 159 wherekeyvalues: list of ???, optional 160 160 Default value is an empty list. 161 161 162 strict: boolean 162 strict: boolean, optional 163 163 Decides if everything from keynames and keyvalues 164 164 is written out the grib file (False) or only those 165 165 meeting the where statement (True). Default is False. 166 166 167 filemode: 167 filemode: string, optional 168 168 Sets the mode for the output file. Default is "w". 169 169 … … 231 231 Filename of the input file to read the grib messages from. 232 232 233 selectWhere: boolean 233 selectWhere: boolean, optional 234 234 Decides if to copy the keynames and values equal to (True) or 235 235 different to (False) the keynames/keyvalues list passed to the 236 236 function. Default is True. 237 237 238 keynames: list of ??? 238 keynames: list of ???, optional 239 239 List of keynames. Default is an empty list. 240 240 241 keyvalues: list of ??? 241 keyvalues: list of ???, optional 242 242 List of keynames. Default is an empty list. 243 243 244 filemode: 244 filemode: string, optional 245 245 Sets the mode for the output file. Default is "w". 246 246 … … 288 288 ''' 289 289 @Description: 290 Create index f rom a list of files if it does not exist or290 Create index file from a list of files if it does not exist or 291 291 read an index file. 292 292 293 293 @Input: 294 index_keys: list of ??? 294 index_keys: list of strings, optional 295 Contains the list of key parameter names from 296 which the index is to be created. 295 297 Default is a list with a single entry string "mars". 296 298 297 index_file: string 299 index_file: string, optional 298 300 Filename where the indices are stored. 299 301 Default is "my.idx". … … 310 312 print("Use existing index file: %s " % (index_file)) 311 313 else: 312 #AP does the for loop overwrite the iid all the time?313 314 for file in self.filename: 314 315 print("Inputfile: %s " % (file)) … … 317 318 else: 318 319 grib_index_add_file(self.iid, file) 319 #AP or does the if has to be in the for loop? 320 #AP would make more sense? 320 321 321 if self.iid is not None: 322 322 grib_index_write(self.iid, index_file) 323 323 324 print('... index done') 325 324 326 return self.iid 325 327
Note: See TracChangeset
for help on using the changeset viewer.