user2975787
user2975787

Reputation: 83

Increase Heap Size Weka

I know that this question has been asked multiple times before, and most of you who provided an answer to the question of how to increase the heap size have said that you cannot use command line interface to do this but that you have to get into RunWeka.ini and change max heap size= 1024M to max heap size = 2048 M. However, when I try to save the changes I made to RunWeka.ini, I get warning saying access to this fie is denied. I tried viewing it on Notepad and saving it, but access was denied, I tried it on Textpad, but access denied. is there ANY way to increase heap size?

Upvotes: 1

Views: 22440

Answers (6)

asccondor
asccondor

Reputation: 51

Since this is the first Google-Result for Stack-Overflow:

what worked for me, on Ubuntu 20.04 with weka 3.8.6

open the weka.sh file and change MEMORY= to MEMORY="4096m"

then run weka.sh

Upvotes: 1

Ameer Sameer Hamood
Ameer Sameer Hamood

Reputation: 11

Run this command in your terminal:

java -Xmx1024m -jar weka.jar

in this section. Or open this file in notepad(run as administrator) from the installation file of Weka as

C:\Program Files\Weka-3-9

then run RunWeka configuration file then go ...

# the heap size (or any other JVM option)
#javaOpts=%JAVA_OPTS%
javaOpts=%JAVA_OPTS% -Xmx1024m

Upvotes: 1

netskink
netskink

Reputation: 4539

On Debian, sudo vi /usr/bin/weka and change the MEMORY='256m' to MEMORY=1024m'

Upvotes: 1

Ismail Mustapha
Ismail Mustapha

Reputation: 1

I had a similar problem but what I did was to first cut the weka.ini file to another location on my pc, changed the maxheap size to my desired size and save before returning it to the weka folder. Guess what? it worked for me.

Upvotes: 0

Du-Lacoste
Du-Lacoste

Reputation: 12767

You can increase the heap size of the tool weka using the terminal. Run this command on the terminal. It will increase the heap size of the tool weka.

java -Xmx1024m -jar weka.jar

Upvotes: 4

ariewahyu
ariewahyu

Reputation: 21

Run as administrator first. In windows, right click on notepad, run as administrator, then you can open RunWeka.ini, modify it and save the changes.

Upvotes: 1

Related Questions