The Data Mining Forum                             open-source data mining software data mining conferences Data Science for Social and Behavioral Analytics DSSBA 2022 data science journal
IMPORTANT: This is the old Data Mining forum.
I keep it online so that you can read the old messages.

Please post your new messages in the new forum: https://forum2.philippe-fournier-viger.com/index.php
 
Null Pointer Exception
Posted by: Jashma
Date: February 10, 2019 09:27AM

Hi,
I am facing a problem while running the MainTestNegFIN.java file in eclipse. When I run the file with the input test files given in the SPMF package it works fine but when I run it using the mushrooms.txt dataset on the SPMF website it gives me a null pointer exception. Could anyone tell me why that is so. My file is in the same directory as the rest of the test files given by SPMF package. I still get the following error

Exception in thread "main" java.lang.NullPointerException
at spmfTest/ca.pfv.spmf.test.MainTestNegFIN.fileToPath(MainTestNegFIN.java:35)
at spmfTest/ca.pfv.spmf.test.MainTestNegFIN.main(MainTestNegFIN.java:20)

Please let me know what I am doing wrong

Options: ReplyQuote
Re: Null Pointer Exception
Date: February 12, 2019 09:11AM

Hi,

It means that the path for the input file is incorrect.

I think that you have perhaps changed:

String input = fileToPath("contextPasquier99.txt"winking smiley;

to:

String input = "mushrooms.txt";

but you should have used:

String input = fileToPath("mushrooms.txt"winking smiley;

Or perhaps that you have mispelled the name of the file or something like that!

In any case, the problem is that the file cannot be accessed by the algorithm due to some problem with the path to the file.

Best regards,



Edited 2 time(s). Last edit at 02/12/2019 09:12AM by webmasterphilfv.

Options: ReplyQuote


This forum is powered by Phorum and provided by P. Fournier-Viger (© 2012).
Terms of use.