.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.47.3. .TH HFST-REWEIGHT "1" "August 2018" "HFST" "User Commands" .SH NAME hfst-reweight \- =Reweight transducer weights simply .SH SYNOPSIS .B hfst-reweight [\fI\,OPTIONS\/\fR...] [\fI\,INFILE\/\fR] .SH DESCRIPTION Reweight transducer weights simply .SS "Common options:" .TP \fB\-h\fR, \fB\-\-help\fR Print help message .TP \fB\-V\fR, \fB\-\-version\fR Print version info .TP \fB\-v\fR, \fB\-\-verbose\fR Print verbosely while processing .TP \fB\-q\fR, \fB\-\-quiet\fR Only print fatal erros and requested output .TP \fB\-s\fR, \fB\-\-silent\fR Alias of \fB\-\-quiet\fR .SS "Input/Output options:" .TP \fB\-i\fR, \fB\-\-input\fR=\fI\,INFILE\/\fR Read input transducer from INFILE .TP \fB\-o\fR, \fB\-\-output\fR=\fI\,OUTFILE\/\fR Write output transducer to OUTFILE .SS "Reweighting options:" .TP \fB\-a\fR, \fB\-\-addition\fR=\fI\,AVAL\/\fR add AVAL to matching weights .TP \fB\-b\fR, \fB\-\-multiplier\fR=\fI\,BVAL\/\fR multiply matching weights by BVAL .TP \fB\-F\fR, \fB\-\-function\fR=\fI\,FNAME\/\fR operate matching weights by FNAME .TP \fB\-l\fR, \fB\-\-lower\-bound\fR=\fI\,LVAL\/\fR match weights greater than LVAL .TP \fB\-u\fR, \fB\-\-upper\-bound\fR=\fI\,UVAL\/\fR match weights less than UVAL .TP \fB\-I\fR, \fB\-\-input\-symbol\fR=\fI\,ISYM\/\fR match arcs with input symbol ISYM .TP \fB\-O\fR, \fB\-\-output\-symbol\fR=\fI\,OSYM\/\fR match arcs with output symbol OSYM .TP \fB\-S\fR, \fB\-\-symbol\fR=\fI\,SYM\/\fR match arcs with input or output symbol SYM or both .TP \fB\-e\fR, \fB\-\-end\-states\-only\fR match end states only, no arcs .TP \fB\-A\fR, \fB\-\-arcs\-only\fR match arcs only, no end states .TP \fB\-T\fR, \fB\-\-tsv\-file\fR=\fI\,TFILE\/\fR read reweighting rules from TFILE .PP If OUTFILE or INFILE is missing or \-, standard streams will be used. Format of result depends on format of INFILE If AVAL, BVAL or FNAME are omitted, they default to neutral elements of addition, multiplication or identity function. If LVAL or UVAL are omitted, they default to minimum and maximum values of the weight structure. If ISYM, OSYM or SYM are omitted, they default to a value that matches all arcs. Only one ISYM, OSYM and SYM can be given. .PP Float values are parsed with strtod(3) and integers strtoul(3). The functions allowed for FNAME are float functions with parameter count of 1 and a matching return value: abs, acos, asin, ... sqrt, tan, tanh .PP The precedence of operands follows the formula BVAL * FNAME(w) + AVAL. The formula is applied iff: ((LVAL <= w) && (w <= UVAL)), where w is weight of arc, and (ISYM == i) && (OSYM == o) && ((SYM == i) || (SYM == o)) ^^ (end state && \fB\-e\fR). .PP TFILE should contain lines with tab\-separated pairs of SYM and AVAL or BVAL. AVAL values must be preceded by a + character, BVAL should be given as plain digits. Comment lines starting with # and empty lines are ignored. .PP Weights are by default modified for all arcs and end states, unless option \fB\-\-end\-states\-only\fR or \fB\-\-arcs\-only\fR is used. .SH "REPORTING BUGS" Report bugs to or directly to our bug tracker at: .PP hfst\-reweight home page: .br General help using HFST software: .SH COPYRIGHT Copyright \(co 2017 University of Helsinki, License GPLv3: GNU GPL version 3 .br This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.