fiona.fio package¶
Submodules¶
fiona.fio.bounds module¶
$ fio bounds
fiona.fio.calc module¶
fiona.fio.cat module¶
fio-cat
fiona.fio.collect module¶
fio-collect
fiona.fio.distrib module¶
$ fio distrib
fiona.fio.dump module¶
fio-dump
fiona.fio.env module¶
$ fio env
fiona.fio.filter module¶
$ fio filter
fiona.fio.helpers module¶
Helper objects needed by multiple CLI commands.
- fiona.fio.helpers.eval_feature_expression(feature, expression)¶
- fiona.fio.helpers.id_record(rec)¶
Converts a record’s id to a blank node id and returns the record.
- fiona.fio.helpers.make_ld_context(context_items)¶
Returns a JSON-LD Context object.
- fiona.fio.helpers.nullable(val, cast)¶
- fiona.fio.helpers.obj_gen(lines, object_hook=None)¶
Return a generator of JSON objects loaded from
lines
.
- fiona.fio.helpers.recursive_round(obj, precision)¶
Recursively round coordinates.
fiona.fio.info module¶
$ fio info
fiona.fio.insp module¶
$ fio insp
fiona.fio.load module¶
$ fio load
fiona.fio.ls module¶
$ fiona ls
fiona.fio.main module¶
Main click group for the CLI. Needs to be isolated for entry-point loading.
- fiona.fio.main.configure_logging(verbosity)¶
fiona.fio.options module¶
Common commandline options for fio
- fiona.fio.options.cb_key_val(ctx, param, value)¶
click callback to validate –opt KEY1=VAL1 –opt KEY2=VAL2 and collect in a dictionary like the one below, which is what the CLI function receives. If no value or None is received then an empty dictionary is returned.
- {
‘KEY1’: ‘VAL1’, ‘KEY2’: ‘VAL2’
}
Note: ==VAL breaks this as str.split(‘=’, 1) is used.
- fiona.fio.options.cb_layer(ctx, param, value)¶
Let –layer be a name or index.
- fiona.fio.options.cb_multilayer(ctx, param, value)¶
Transform layer options from strings (“1:a,1:b”, “2:a,2:c,2:z”) to { ‘1’: [‘a’, ‘b’], ‘2’: [‘a’, ‘c’, ‘z’] }
- fiona.fio.options.validate_multilayer_file_index(files, layerdict)¶
Ensure file indexes provided in the –layer option are valid
fiona.fio.rm module¶
Module contents¶
Fiona’s command line interface
- fiona.fio.with_context_env(f)¶
Pops the Fiona Env from the passed context and executes the wrapped func in the context of that obj.
Click’s pass_context decorator must precede this decorator, or else there will be no context in the wrapper args.