man.diff
来自「speech signal process tools」· DIFF 代码 · 共 289 行
DIFF
289 行
.\" Copyright (c) 1987, 1990 Entropic Speech, Inc.; All rights reserved.\" @(#)addsd.1 3.12 02 Apr 1997 ESI.TH ADDSD 1\-ESPS 02 Apr 1997.ds ]W "\fI\s+4\ze\h'0.05'e\s-4\v'-0.4m'\fP\(*p\v'0.4m'\ Entropic Speech, Inc..SH "NAME"addsd - add ESPS sampled data files with optional scaling.brmultsd - multiply ESPS sampled data files with optional scaling.SH "SYNOPSIS".B addsd[.BI \-x " debug_level"] [.BI \-r " range"] [.BI \-p " range"] [.BI \-g " scale"] [.BI \-z] [.BI \-t] .I "file1 file2 file3".br.B multsd[.BI \-x " debug_level"] [.BI \-r " range"] [.BI \-p " range"] [.BI \-g " scale"] [.BI \-z] [.BI \-t] .I "file1 file2 file3".SH "DESCRIPTION".PP\fIaddsd\fP (1\-\s-1ESPS\s+1) and \fImultsd\fP (1\-\s-1ESPS\s+1) are thesame binary file. The function the program does (either adding or multiplying)depends on the name that is used to call it. The options and syntax are the same for both adding and multiplying. Because the calling name is usedin the program logic, both \fIaddsd\fP (1\-\s-1ESPS\s+1) and \fImultsd\fP (1\-\s-1ESPS\s+1) cannot be linked or copied to new names.Below only \fIaddsd\fP (1\-\s-1ESPS\s+1) is described, but the descriptionof \fImultsd\fP (1\-\s-1ESPS\s+1) is completely analogous..PP.I Addsdtakes sampled data from .I file1,adds it sample-by-sample to the sampled data in .I file2,possibly scaling the data in .I file2 first, and outputs the results as an ESPS FEA_SD file.I file3.If there are not enough records in .I file2, and if the.B \-toption is not used, .I addsdreuses .I file2,starting with its first record. .PPBoth.I file1and.I file2must be ESPS FEA_SD files, and they must have the same sampling frequency (record_freq); otherwise.I addsdexits with an error message. The output file data type is selected to "cover" the two input datatypes. That is, all values of the input types can be stored in the outputtype. For example, if one file is type SHORT_CPLX and the other is type FLOAT, the output type is FLOAT_CPLX.If "\-" is supplied in place of .I file1,then standard input is used. If "\-" is supplied in place of .I file3,standard output is used. .SH OPTIONS.PPThe following options are supported:.TP.BI \-x " debug_level"If .I debug_levelis positive,.I addsdprints debugging messages and other information on the standard erroroutput. The messages proliferate as the .I debug_levelincreases. If.I debug_levelis 0, no messages are printed. The default is 0. Levels up through 2are supported currently. .TP.BI \-p " range"Selects a subrange of records from .I file1using the format .I start\-endor.IR start:end .Either .I startor .I endmay be omitted, in which case the omitted parameter defaults respectivelyto the start or end of .I file1. The first record in .I file1is considered to be frame 1, regardless of its position relative to anyoriginal source file. The default range is the entire input file.I file1. The selected subrange from .I file1is then added to the (possibly scaled) data from the .I file2,starting with the first record of .I file2.If the subrange does not exist in.I "file1, addsd"exits with an error message. .TP.BI \-r " range"\fB-r\fP is a synonym for \fB-p\fP..TP.BI \-g " scale"Causes .I addsdto multiply the data in .I file2by .I scalebefore adding it to the data in .I file1. The format for .I scale is either integer or floating point. .TP.BI \-zSupresses warning messages that normally are generated if the contents of .I file2are used more than once. .TP.BI \-tTruncates the processing if there are not enough records in .I file2.In this case, .I file3will contain as many records as there are in .I file2or, if the .B \-poption is used, as many records as in the intersection of .I rangeand the full range of .I file2. .SH "ESPS PARAMETERS".PPThe ESPS parameter file is not read by .I addsd. .SH ESPS COMMON.PPIf Common processing is enabled, the following items are read from the ESPSCommon File provided that \fIfile1\fP is not standard input, and providedthat the Common item \fIfilename\fP matches the input file name\fIfile1\fP:.IP.I "start - integer".IPThis is the starting point in \fIfile1\fP..sp.I "nan - integer".IPThis is the number of points to add from \fIfile1\fP. .spIf \fIstart\fR and/or \fInan\fR are not given in the common file, or if thecommon file can't be opened for reading, then \fIstart\fR defaults to thebeginning of the file and \fInan\fR defaults to the number of points in thefile. In all cases, values of \fIstart\fP and \fInan\fP are ignoredif the \fB\-p\fP is used. .PPIf Common processing is enabled, the following items are written into theESPS Common file provided that the output file is not <stdout>:.IP.I "start - integer".IPThe starting point (1) in the output file .I file3..sp.I "nan - integer".IPThe number of points in the output file .I file3.sp.I "prog - string".IPThis is the name of the program (\fIaddsd\fP in this case)..sp.I "filename - string".IPThe name of the output file.I file3. .PPESPS Common processing may be disabled by setting the environment variableUSE_ESPS_COMMON to \fBoff\fR. The default ESPS Common file is \fI.espscom\fR in the user's home directory. This may be overidden by settingthe environment variable ESPSCOM to the desired path. User feedback ofCommon processing is determined by the environment variable ESPS_VERBOSE,with 0 causing no feedback and increasing levels causing increasinglydetailed feedback. If ESPS_VERBOSE is not defined, a default value of 3 isassumed..SH ESPS HEADERS.PPThe following items are copied from the header of .I file1to the header of .I file3:.RS 5\fI.nfvariable.commentvariable.referrecord_freq.fi\fP.RE.PPIf the .B \-goption is used, a generic header item \fIscale\fPis added to the output file header that contains the \fB\-g\fPspecified value..I Max_value in .I file3is not set..PPThe generic header item \fIstart_time\fP is written in the output file. The value written is computed by taking the \fIstart_time\fP value from the header of the first input file (or zero, if such a header item doesn'texist) and adding to it the relative time from the first recordin the file to the first record processed. .SH "SEE ALSO".PP.nfESPS (5\-ESPS), FEA_SD (5\-ESPS), record (1\-ESPS), copysd (1\-ESPS).fi.SH "WARNINGS".PPIf there are not enough records in .I file2\- i.e., if .I addsdhas to start over at the beginning of .I file2,\- a warning message is printed. This warning is inhibited by the.B \-zoption, and does not apply if.B \-tis used. .SH "BUGS".PPNone known..SH "AUTHOR".PPAjaipal S. Virdy..brModified for ESPS 3.0 by David Burton and John Shore..brModified for FEA_SD by David Burton..brModified to support multiplication by David Burton.
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?