08-21-2009
Usted debe utilizar inglés
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hi
I have a file with data arranged into columns. The first column is the chromosome name.
When I use grep to subset only rows with chr1, I get chr1 but also chr10, chr11,..
How do I get only rows with chr1?
grep chr1 filein > fileout
head fileout
chr1 59757841
chr11 108258691 ... (2 Replies)
Discussion started by: jdhahbi
2 Replies
2. UNIX for Dummies Questions & Answers
Hi,
I'm struggling with a regex that would match a 'b' that follows an 'a' and is at the end of a string of non-white characters. For example:
Line 1: aba abab b abb aab bab baa
I can find the right strings but I'm lacking knowledge of how to "discard" the bits that precede bs.... (2 Replies)
Discussion started by: machinogodzilla
2 Replies
3. Shell Programming and Scripting
Hi all,
any idea how to match the following:
char*<no or any string or space> buf and
char *<no or any string or space> buf
i need to capture the buf characters too.
currently i need two checks to cover this:
#search char* <any string> buf or char *<any string> buf
@noarray =... (2 Replies)
Discussion started by: ChaMeN
2 Replies
4. Shell Programming and Scripting
Hi all,
I am looking for a regex syntax to match repeated appearance. Likes,
']+]+' matches for string '65A SOME MORE AND 78B'
Now, this gets messy if I need to extract all such repeated appearance. I don't want to write ] four or five times for matching repeated appearance.
Thanks in... (2 Replies)
Discussion started by: guruparan18
2 Replies
5. Shell Programming and Scripting
I am trying to match a similar line using grep with regular expression
the line is
/remote/mac/pbbbb/abc/def/hij/hop/include/abc/tif/element/test/testfiles/Office.cpp:57: const OfficeType& getType().get() const;
I just need to extract the bold characters using grep with regular expression.... (5 Replies)
Discussion started by: prasbala
5 Replies
6. Shell Programming and Scripting
hi everyone
suppose we have two scenario
echo ABCD | grep \{4\}
DATE
echo SYSDATE | grep \{4\}
SYSDATE
i want to match the string of four length only please help (5 Replies)
Discussion started by: aishsimplesweet
5 Replies
7. Shell Programming and Scripting
Hi,
I read the book of <<unix shell programming>>. The regular expression ^\(.\)\1 matches the first character on the line and stores it in register 1. Then the expression matches whatever is stored in the register 1, as specified by the \1. The net effect of this regular expression is to match... (2 Replies)
Discussion started by: jianma
2 Replies
8. Homework & Coursework Questions
Hi Everybody!
I need some help with a regular expression in Perl that will match files named messages, but also files named message.1, message.2 and so on. So really I need one that will find messages and messages that might be followed by a period and a digit without matching other files like... (2 Replies)
Discussion started by: Hax0rc1ph3r
2 Replies
9. Shell Programming and Scripting
I cannot seem to get this to work correct:
my ($k, $v) = split(/F/, $fc{$DIR}{symbolic}, 2);
Below is the input (the $fc{$DIR}{symbolic} variable):
QMH2562 FW:v5.06.03 DVR:v8.03.07.15.05.09-kbut i also need it to break on FV:
Emulex NC553i FV4.2.401.6 DV8.3.5.86.2pthe code above... (2 Replies)
Discussion started by: rusted_planet
2 Replies
10. Shell Programming and Scripting
echo 20110101 | awk '{ print match($0,/^((17||18||19||20)|)-*(|0|1)-*(|0||3)$/))
I am getting a match for the above, where as it shouldn't, as there is no hyphen in the echoed date.
Another question is what is the difference between || and | in the above statement (4 Replies)
Discussion started by: tostay2003
4 Replies
LEARN ABOUT DEBIAN
liblinear-train
LIBLINEAR-TRAIN(1) General Commands Manual LIBLINEAR-TRAIN(1)
NAME
liblinear-train - train a linear classifier and produce a model
SYNOPSIS
liblinear-train [options] training_set_file [model_file]
DESCRIPTION
liblinear-train trains a linear classifier using liblinear and produces a model suitable for use with liblinear-predict(1).
training_set_file is the file containing the data used for training. model_file is the file to which the model will be saved. If
model_file is not provided, it defaults to training_set_file.model.
To obtain good performances, sometimes one needs to scale the data. This can be done with svm-scale(1).
OPTIONS
A summary of options is included below.
-s type
Set the type of the solver:
0 ... L2-regularized logistic regression
1 ... L2-regularized L2-loss support vector classification (dual) (default)
2 ... L2-regularized L2-loss support vector classification (primal)
3 ... L2-regularized L1-loss support vector classification (dual)
4 ... multi-class support vector classification
5 ... L1-regularized L2-loss support vector classification
6 ... L1-regularized logistic regression
7 ... L2-regularized logistic regression (dual)
-c cost
Set the parameter C (default: 1)
-e epsilon
Set the tolerance of the termination criterion
For -s 0 and 2:
|f'(w)|_2 <= epsilon*min(pos,neg)/l*|f'(w0)_2, where f is
the primal function and pos/neg are the number of positive/negative data
(default: 0.01)
For -s 1, 3, 4 and 7:
Dual maximal violation <= epsilon; similar to libsvm (default: 0.1)
For -s 5 and 6:
|f'(w)|_inf <= epsilon*min(pos,neg)/l*|f'(w0)|_inf, where f is the primal
function (default: 0.01)
-B bias
If bias >= 0, then instance x becomes [x; bias]; if bias < 0, then
no bias term is added (default: -1)
-wi weight
Weight-adjusts the parameter C of class i by the value weight
-v n n-fold cross validation mode
-q Quiet mode (no outputs).
EXAMPLES
Train a linear SVM using L2-loss function:
liblinear-train data_file
Train a logistic regression model:
liblinear-train -s 0 data_file
Do five-fold cross-validation using L2-loss SVM, using a smaller stopping tolerance 0.001 instead of the default 0.1 for more accurate
solutions:
liblinear-train -v 5 -e 0.001 data_file
Train four classifiers:
positive negative Cp Cn
class 1 class 2,3,4 20 10
class 2 class 1,3,4 50 10
class 3 class 1,2,4 20 10
class 4 class 1,2,3 10 10
liblinear-train -c 10 -w1 2 -w2 5 -w3 2 four_class_data_file
If there are only two classes, we train ONE model. The C values for the two classes are 10 and 50:
liblinear-train -c 10 -w3 1 -w2 5 two_class_data_file
Output probability estimates (for logistic regression only) using liblinear-predict(1):
liblinear-predict -b 1 test_file data_file.model output_file
SEE ALSO
liblinear-predict(1), svm-predict(1), svm-train(1)
AUTHORS
liblinear-train was written by the LIBLINEAR authors at National Taiwan university for the LIBLINEAR Project.
This manual page was written by Christian Kastner <debian@kvr.at>, for the Debian project (and may be used by others).
March 08, 2011 LIBLINEAR-TRAIN(1)