Indra M | 29 May 07:17 2016
Picon

Java/R interface error : SLF4J : CLASS PATH CONTAINS MULTIPLE SLF4J BINDINGS

Hi everyone

I am trying to install RWeka Pluggin. 

I am getting error in JAVA/R interface. If anyone can advice me on this how to resolve this:

SLF4J : CLASS PATH CONTAINS MULTIPLE SLF4J BINDINGS

Its with Hadoop packages. 




Please help me in this regard.


Thanks in advance.


--
Best regards,

Dr. Indrajit Mandal

_______________________________________________
Wekalist mailing list
Send posts to: Wekalist <at> list.waikato.ac.nz
List info and subscription status: https://list.waikato.ac.nz/mailman/listinfo/wekalist
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Indra M | 28 May 09:26 2016
Picon

Spark Error: in Knowledge Flow

Hi Mark

I have getting the timed out error while executing Spark modules in Knowledge Flow:

12:32:37: Futures timed out after [10000 milliseconds]

How can I fix this error? Please advice.

I have attached the log file too. Please help.










12:32:19: Weka Knowledge Flow was written by Mark Hall
12:32:19: Weka Knowledge Flow
12:32:19: (c) 2002-2016 The University of Waikato, Hamilton, New Zealand
12:32:19: Saturday, 28 May 2016
12:32:24: [FlowRunner] launching flow start points in parallel...
12:32:24: [FlowRunner] Launching flow 1...
12:32:24: [FlowRunner] Launching flow 2...
12:32:24: Setting job name to: WekaKF:ARFF instances header job+Randomized and stratified split job
12:32:24: [FlowRunner] Launching flow 3...
12:32:24: [FlowRunner] Launching flow 4...
12:32:37: Futures timed out after [10000 milliseconds]




--
Attachment (weka.log): application/octet-stream, 56 KiB
_______________________________________________
Wekalist mailing list
Send posts to: Wekalist <at> list.waikato.ac.nz
List info and subscription status: https://list.waikato.ac.nz/mailman/listinfo/wekalist
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Dee D | 28 May 20:10 2016
Picon

Re: InfoGainAttributeEval, which attributes to retain

Hi Eibe,

Thank you very much for your answer. This solution allows the classifier select the attributes. However,
it is possible to select attributes without the use of a classifier. Please see previous post relating to this:

    --> From: Wekalist Digest, Vol 158, Issue 7
    --> You will need to specify in the Ranker search method, which is the search method you need to use when
applying attribute evaluators (i.e., AttributeEval classes), how many attributes you want to keep
(alternatively, you can also specify a threshold on the criterion you are using, e.g., correlation).
    -->
    --> Cheers,
    --> Eibe

    -->> I would like to understand how AttributeSelectedClassifier works.
    -->> 
    -->> Using SMO and CorrelationAttributeEval as an example:
    -->> 
    -->> CorrelationAttributeEval filter generates weights for all the attributes. How does the classifier
know which attributes should be selected?
    -->> 
    -->> Thank you,
    -->> Dee

My question is whether we let the classifier select attribute or we do it ourselves depends on the type of the
filter? E.g. for Correlation we use threshold and for InfoGain (please see below) we use the classifier?

> Subject: Re: [Wekalist] InfoGainAttributeEval, which attributes to
        retain
> Message-ID: <B528179E-C291-441F-BCFD-004F4923156D <at> waikato.ac.nz>
> Content-Type: text/plain; charset=iso-8859-1

> It's best not to make any manual choices. Instead, use something like this:
>
>  java weka.Run .AttributeSelectedClassifier -S ".RankSearch -A .InfoGainAttributeEval" -E
".WrapperSubsetEval -B .J48" -W .J48 -t ~/datasets/UCI/glass.arff
>
> In WEKA 3.8, RankSearch is available in the attributeSelectionSearchMethods package. (Perhaps it
should probably have remained in the core because it's so useful.)
>
> Cheers,
> Eibe

>> On 7 May 2016, at 06:50, Dee D <winvis245 <at> hotmail.com> wrote:
>>
>> Hi,
>>
>> How does one go about choosing a threshold for retaining attributes in InfoGainAttributeEval? Would
that be based on percentage, e.g., top 90%? Would similar levels apply to other attribute selectors like ReliefFAttributeEval?
>>
>> thanks
>> Dee
------------------------------

thank you
Dee
_______________________________________________
Wekalist mailing list
Send posts to: Wekalist <at> list.waikato.ac.nz
List info and subscription status: https://list.waikato.ac.nz/mailman/listinfo/wekalist
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

Julien Saumande | 28 May 00:50 2016
Picon

Classify a text with weka after classifier has been trained

Hi all,

I am a beginner with weka. 

I have managed to import dataset from the disk (one folder by category, all text related to this category inside the folder), apply StringToWordVector with tokenizer, train a Naive Multniomial categorizer ... The code is below (it is c# but Java is ok of course) 

However, I can hardly find information on how to use the categorizer on a project. Say I have a text with unknown category, input by a user, how can I just apply the categorizer to this text and infer the category it belongs to ? (code "// what to do here below"). 

Any help would be greatly appreciated ;-) 

Thanks in advance

Julien

string filepath = <at> "C:\Users\Julien\Desktop\Meal\";ClassificationDatasetHelper classHelper = new ClassificationDatasetHelper();

weka.core.converters.TextDirectoryLoader tdl = new

weka.core.converters.TextDirectoryLoader();

tdl.setDirectory(new java.io.File(filepath));

 tdl.setCharSet("UTF-8");

 weka.core.Instances insts = tdl.getDataSet();

weka.filters.unsupervised.attribute.StringToWordVector swv = new weka.filters.unsupervised.attribute.StringToWordVector();

swv.setInputFormat(insts);

swv.setDoNotOperateOnPerClassBasis(false);

swv.setOutputWordCounts(true);

swv.setWordsToKeep(1000);

swv.setIDFTransform(true);

swv.setMinTermFreq(1);

swv.setDoNotOperateOnPerClassBasis(false);

swv.setPeriodicPruning(-1);

weka.core.tokenizers.NGramTokenizer tokenizer = new weka.core.tokenizers.NGramTokenizer();

tokenizer.setNGramMinSize(2);

tokenizer.setNGramMaxSize(2);

swv.setTokenizer(tokenizer);


insts = weka.filters.Filter.useFilter(insts, swv);

insts.setClassIndex(0);

weka.classifiers.Classifier cl = new weka.classifiers.bayes.NaiveBayesMultinomial();

int trainSize = insts.numInstances() * percentSplit / 100;

int testSize = insts.numInstances() - trainSize;

weka.core.Instances train = new weka.core.Instances(insts, 0, trainSize);

cl.buildClassifier(train);

string s = "Try to classify this text";

weka.core.Instance instanceToClassify = new weka.core.Instance();

    // what to do here

    // ???

double predictedClass = cl.classifyInstance(instanceToClassify);


_______________________________________________
Wekalist mailing list
Send posts to: Wekalist <at> list.waikato.ac.nz
List info and subscription status: https://list.waikato.ac.nz/mailman/listinfo/wekalist
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
祝迪 | 27 May 09:20 2016
Picon

Report a bug in Class Instances

Sorry, I just find that JAVA ArrayList's removeAt method has been removed and you usage of remove method is correct. But Class Instances's delete method indeed didn't work properly.

发件人: "zhu.scin65536";<zhu.scin65536 <at> gmail.com>;
发送时间: 2016年5月27日(星期五) 下午2:43
收件人: "wekalist"<wekalist <at> list.waikato.ac.nz>;
主题: Report a bug in Class Instances

Version 3.8

Class Instances

  • java.lang.Object
    • java.util.AbstractCollection<E>
      • java.util.AbstractList<Instance>
        • weka.core.Instances

 ​When I use Instances.delete(index) method, it don't work properly. I find it always deletes the last Instance rather than the one at the given position.
So I check the source code (Instancs.java), and I find you used .remove method rather than removeAt in public Instance remove(int index) (line 1101). I think this is why it can't work properly.

Thank you for your work!
Sincerely,
Di Zhu
_______________________________________________
Wekalist mailing list
Send posts to: Wekalist <at> list.waikato.ac.nz
List info and subscription status: https://list.waikato.ac.nz/mailman/listinfo/wekalist
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
祝迪 | 27 May 08:43 2016
Picon

Report a bug in Class Instances

Version 3.8 

Class Instances

  • java.lang.Object
    • java.util.AbstractCollection<E>
      • java.util.AbstractList<Instance>
        • weka.core.Instances

 ​When I use Instances.delete(index) method, it don't work properly. I find it always deletes the last Instance rather than the one at the given position.
So I check the source code (Instancs.java), and I find you used .remove method rather than removeAt in public Instance remove(int index) (line 1101). I think this is why it can't work properly. 

Thank you for your work!
Sincerely,
Di Zhu
_______________________________________________
Wekalist mailing list
Send posts to: Wekalist <at> list.waikato.ac.nz
List info and subscription status: https://list.waikato.ac.nz/mailman/listinfo/wekalist
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Baskar Jayaraman | 27 May 02:59 2016
Picon

Executing Auto-WEKA 2.0 through java code...

I need to generate a model for each of a number of data sets (sequentially or,  in parallel by using a framework like java concurrency). I would like to try Auto-WEKA on these data sets not using UI but programmatically using Java. Is it as simple as instaling Auto-WEKA, including the jar in the eclipse project, constructing an instance of AutoWEKAClassifier and executing its buildClassifier as shown below:

AutoWEKAClassifier autoweka = new AutoWEKAClassifier();
autoweka.setTimeLimit(60);//in minutes
autoweka.setMemLimit(1024);//in MB
autoweka.setDebug(true);
autoweka.setSeed(123);
autoweka.buildClassifier(traindata);

I am using weka 3.8.0 and Auto-WEKA 2.0.

Appreciate any pointers. Thanks.

Baskar
 
_______________________________________________
Wekalist mailing list
Send posts to: Wekalist <at> list.waikato.ac.nz
List info and subscription status: https://list.waikato.ac.nz/mailman/listinfo/wekalist
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Gorn | 26 May 10:27 2016
Picon

cannot load imageFilters package

Dear wekalist,

I try to install imageFilters package from PackageManager, but I get this
error.  Please advise.

Gorn

javax.net.ssl.SSLHandshakeException:
sun.security.validator.ValidatorException: PKIX path building failed:
sun.security.provider.certpath.SunCertPathBuilderException: unable to find
valid certification path to requested target
	at sun.security.ssl.Alerts.getSSLException(Unknown Source)
	at sun.security.ssl.SSLSocketImpl.fatal(Unknown Source)
	at sun.security.ssl.Handshaker.fatalSE(Unknown Source)
	at sun.security.ssl.Handshaker.fatalSE(Unknown Source)
	at sun.security.ssl.ClientHandshaker.serverCertificate(Unknown Source)
	at sun.security.ssl.ClientHandshaker.processMessage(Unknown Source)
	at sun.security.ssl.Handshaker.processLoop(Unknown Source)
	at sun.security.ssl.Handshaker.process_record(Unknown Source)
	at sun.security.ssl.SSLSocketImpl.readRecord(Unknown Source)
	at sun.security.ssl.SSLSocketImpl.performInitialHandshake(Unknown Source)
	at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)
	at sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)
	at sun.net.www.protocol.https.HttpsClient.afterConnect(Unknown Source)
	at
sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Unknown
Source)
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(Unknown
Source)
	at sun.net.www.protocol.http.HttpURLConnection.access$200(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection$9.run(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection$9.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.AccessController.doPrivilegedWithCombiner(Unknown Source)
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
Source)
	at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(Unknown
Source)
	at
weka.core.packageManagement.DefaultPackageManager.downloadArchive(DefaultPackageManager.java:209)
	at
weka.core.packageManagement.DefaultPackageManager.installPackageFromURL(DefaultPackageManager.java:768)
	at
weka.core.packageManagement.DefaultPackageManager.installPackageFromRepository(DefaultPackageManager.java:753)
	at
weka.core.WekaPackageManager.installPackageFromRepository(WekaPackageManager.java:1938)
	at
weka.gui.PackageManager$InstallTask.doInBackground(PackageManager.java:1307)
	at
weka.gui.PackageManager$InstallTask.doInBackground(PackageManager.java:863)
	at javax.swing.SwingWorker$1.call(Unknown Source)
	at java.util.concurrent.FutureTask.run(Unknown Source)
	at javax.swing.SwingWorker.run(Unknown Source)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
	at java.lang.Thread.run(Unknown Source)
Caused by: sun.security.validator.ValidatorException: PKIX path building
failed: sun.security.provider.certpath.SunCertPathBuilderException: unable
to find valid certification path to requested target
	at sun.security.validator.PKIXValidator.doBuild(Unknown Source)
	at sun.security.validator.PKIXValidator.engineValidate(Unknown Source)
	at sun.security.validator.Validator.validate(Unknown Source)
	at sun.security.ssl.X509TrustManagerImpl.validate(Unknown Source)
	at sun.security.ssl.X509TrustManagerImpl.checkTrusted(Unknown Source)
	at sun.security.ssl.X509TrustManagerImpl.checkServerTrusted(Unknown Source)
	... 30 more
Caused by: sun.security.provider.certpath.SunCertPathBuilderException:
unable to find valid certification path to requested target
	at sun.security.provider.certpath.SunCertPathBuilder.build(Unknown Source)
	at sun.security.provider.certpath.SunCertPathBuilder.engineBuild(Unknown
Source)
	at java.security.cert.CertPathBuilder.build(Unknown Source)
	... 36 more

--
View this message in context: http://weka.8497.n7.nabble.com/cannot-load-imageFilters-package-tp37510.html
Sent from the WEKA mailing list archive at Nabble.com.
_______________________________________________
Wekalist mailing list
Send posts to: Wekalist <at> list.waikato.ac.nz
List info and subscription status: https://list.waikato.ac.nz/mailman/listinfo/wekalist
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

Andria Lan | 26 May 07:01 2016
Picon

Don't find imageFilters package in package manager

Hi everyone, 

I wanted to install "imageFilters" package using package manager, but couldn't find it there. Is it missing from the list or I miss something?

Thanks in advance. 
Andria
_______________________________________________
Wekalist mailing list
Send posts to: Wekalist <at> list.waikato.ac.nz
List info and subscription status: https://list.waikato.ac.nz/mailman/listinfo/wekalist
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Desai Ankit | 25 May 11:14 2016
Picon

distributedWekaSpark error

can anyone help me getting rid of this error or atleast tell me the cause of the error?

ERROR: Job aborted due to stage failure: Task 1 in stage 0.0 failed 1 times, most recent failure: Lost task 1.0 in stage 0.0 (TID 1, localhost): java.io.IOException: Parsed a row that contains a different number of values than there are attributes in the training ARFF header:


actually count of number of attributes and values is matching. then I dont know why this error persist? 

help.

Sincerely, 
--
Ankit Desai
_______________________________________________
Wekalist mailing list
Send posts to: Wekalist <at> list.waikato.ac.nz
List info and subscription status: https://list.waikato.ac.nz/mailman/listinfo/wekalist
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Desai Ankit | 25 May 09:22 2016
Picon

distributedWekaSpark with J48

Dear all,

I have following issue with distributedWekaSpark. 

using knowledge flow I tried using Bupa-Liver-Disorders dataset from UCI repository. 

It has a class attribute with values 1 and 2 as nominal in arff format. 

wekaSpark works with csv only so I converted it into csv format without header row. 

When I tried to load that csv file in knowledge flow it generates an exception saying j48 can not handle a numeric class. 

So i tried to replace 1s with y's and 2s with n's. and again run the same flow. 

Now it says, Number format exception. 

All i need to do is, I want to work with bupa dataset and classify it with 10 fold cv using J48. 

please help. 

--
Ankit Desai
desaiankitb.tk

_______________________________________________
Wekalist mailing list
Send posts to: Wekalist <at> list.waikato.ac.nz
List info and subscription status: https://list.waikato.ac.nz/mailman/listinfo/wekalist
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

Gmane