i.signatures
Manage imagery classification signature files
i.signatures [-p] [type=name] format=name [mapset=name [,name,...]] [remove=name [,name,...]] [rename=from,to [,from,to,...]] [copy=from,to [,from,to,...]] [--verbose] [--quiet] [--qq] [--ui]
Example:
i.signatures format=plain copy=from,to
grass.script.parse_command("i.signatures", type=None, format="plain", mapset=None, remove=None, rename=None, copy=None, flags=None, verbose=False, quiet=False, superquiet=False)
Example:
gs.parse_command("i.signatures", format="json", copy="from,to")
Parameters
type=name
Type of signature file
Allowed values: sig, sigset, libsvm
format=name [required]
Output format
Allowed values: plain, json
Default: plain
plain: Plain text output
json: JSON (JavaScript Object Notation)
mapset=name [,name,...]
Name of mapset to list
Default: current search path
remove=name [,name,...]
Name of file(s) to remove
rename=from,to [,from,to,...]
Name of file to rename
copy=from,to [,from,to,...]
Name of file to copy
-p
Print signature files
--help
Print usage summary
--verbose
Verbose module output
--quiet
Quiet module output
--qq
Very quiet module output
--ui
Force launching GUI dialog
type : str, optional
Type of signature file
Used as: input, sigtype, name
Allowed values: sig, sigset, libsvm
format : str, required
Output format
Used as: name
Allowed values: plain, json
plain: Plain text output
json: JSON (JavaScript Object Notation)
Default: plain
mapset : str | list[str], optional
Name of mapset to list
Default: current search path
Used as: input, mapset, name
remove : str | list[str], optional
Name of file(s) to remove
Used as: input, sigfile, name
rename : list[tuple[str, str]] | tuple[str, str] | list[str] | str, optional
Name of file to rename
Used as: input, sigfile, from,to
copy : list[tuple[str, str]] | tuple[str, str] | list[str] | str, optional
Name of file to copy
Used as: input, sigfile, from,to
flags : str, optional
Allowed values: p
p
Print signature files
verbose: bool, optional
Verbose module output
Default: False
quiet: bool, optional
Quiet module output
Default: False
superquiet: bool, optional
Very quiet module output
Default: False
DESCRIPTION
i.signatures module allows managing signature files:
- "sig" – generated by i.gensig for i.maxlik
- "sigset" – generated by i.gensigset for i.smap
- "libsvm" - generated internally by i.svm.train and used by i.svm.predict for classification. The module can perform multiple actions per run. The order of execution is "copy", "remove", "rename". When the print flag is specified without specifying any type of signature files, it would print all signatures grouped by type.
NOTES
By default the module will list signature files from all mapsets in the
current search path. It is possible to limit listing only to a single
mapset by providing the "mapset" option. The mapset can be also not
listed in the current search path.
Actions "remove" and "rename" operate only on the current mapset
(although accept fully qualified names). The "copy" action will accept a
signature file name from any mapset as its first argument (source file
to copy).
EXAMPLES
Print names of all signature files:
i.signatures -p
Print only signature files of certain type as a JSON:
i.signatures -p type=sigset format=json
Delete signature file called "foo" of type "sig" (i.gensig / i.maxlik).
i.signatures remove=foo type=sig
Copy signature file "bar" from mapset "baz" to current mapset
i.signatures copy=bar@baz,best_version type=sigset
SEE ALSO
i.gensig i.gensigset i.svm.predict
AUTHOR
Maris Nartiss
SOURCE CODE
Available at: i.signatures source code
(history)
Latest change: Wednesday Apr 02 10:01:47 2025 in commit e328b0b