First of all, I am very thankful for this library existing and also is available for python.
I am trying to install the python wrapper for the java implementation I found here:
https://pypi.org/project/spmf/
I was reading through an example to use a json array as an input as I would have to make transformation otherwise. My code looks like this now:
with open("test.json" as BOB:
chains=json.load(BO
spmf = Spmf("AprioriInverse", input_direct=chains,
output_filename="output.txt",
arguments=[0.1, 0.6])
exit()
The main problem is that I am not able to make it work so that the python is picking up or finding the spmf.jar that I downloaded to the spmf to the python lib directory. It is still throwing an error that it cannot find the .jar file.
The error looks like this:
File "test.py", line 34, in <module>
arguments=[0.1, 0.6])
File "/home/evelyn/.local/lib/python3.6/site-packages/spmf/__init__.py", line 36, in __init__
" use the spmf_bin_location_dir argument."
FileNotFoundError: spmf.jar not found. Please use the spmf_bin_location_dir argument.
I put the .jar into this directory:
/home/evelyn/.local/lib/python3.6/site-packages/spmf
Is this not the right place to put it? Or is the wrapper outdated? Or do I have to give the Spmf object the directory as an argument?
I also tried to run the code with the directory argument spmf_bin_location_dir like this:
python3 test.py /home/evelyn/.local/lib/python3.6/site-packages/spmf/
But this didn't work either.
I am stuck with this and I would be very thankful if there might be some help on this.
Thank you very much in advance!
Edited 1 time(s). Last edit at 07/01/2020 04:48AM by webmasterphilfv.