Mengubah heapsize runweka.ini pada Windows7

Default value heapsize saat Weka di-install di suatu computer adalah 128mb. Saat kita melakukan eksperimen dengan data berskala besar, pembatasan di atas menyebabkan adakalanya memory tidak cukup. Untuk mengatasi hal tsb. editlah file RunWeka.ini yang berada di bawah folder Weka (misalnya C:\Program Files\Weka-3-7\ ) memakai wordpad, dan ubahlah nilai heapsize (yang diberi warna merah di bawah) menjadi nilai yang lebih besar. Misalnya menjadi  1024mb.

# Contains the commands for running Weka either with a command prompt
# (“cmd_console”) or without the command prompt (“cmd_default”).
# One can also define custom commands, which can be used with the Weka
# launcher “RunWeka.class”. E.g., to run the launcher with a setup called
# “custom1”, you only need to specify a key “cmd_custom1” which contains the
# command specification.
#
# Notes:
# – This file is not a DOS ini file, but a Java properties file.
# – The settings listed here are key-value pairs, separated by a “=”. Every
#   key can only be listed ONCE.
#
# Author  FracPete (fracpete at waikato dot ac dot nz)
# Version $Revision: 1.3 $

# setups (prefixed with “cmd_”)
cmd_default=javaw -Dfile.encoding=#fileEncoding# -Xmx#maxheap# -classpath “#wekajar#;#cp#” #mainclass#
cmd_console=cmd.exe /K start cmd.exe /K “java -Dfile.encoding=#fileEncoding# -Xmx#maxheap# -classpath \”#wekajar#;#cp#\” #mainclass#”
cmd_explorer=javaw -Dfile.encoding=#fileEncoding# -Xmx#maxheap# -classpath “#wekajar#;#cp#” weka.gui.explorer.Explorer

# placeholders (“#bla#” in command gets replaced with content of key “bla”)
# Note: “#wekajar#” gets replaced by the launcher class, since that jar gets
#       provided as parameter
maxheap=128m
# The MDI GUI
#mainclass=weka.gui.Main
# The GUIChooser
mainclass=weka.gui.GUIChooser
# The file encoding; use “utf-8” instead of “Cp1252” to display UTF-8 characters in the
# GUI, e.g., the Explorer
fileEncoding=Cp1252

# The classpath placeholder. Add any environment variables or jars to it that
# you need for your Weka environment.
# Example with an enviroment variable (e.g., THIRD_PARTY_LIBS):
#   cp=%CLASSPATH%;%THIRD_PARTY_LIBS%
# Example with an extra jar (located at D:\libraries\libsvm.jar):
#   cp=%CLASSPATH%;D:\\\\libraries\\\\libsvm.jar
# Or in order to avoid quadrupled backslashes, you can also use slashes “/”:
#   cp=%CLASSPATH%;D:/libraries/libsvm.jar
cp=%CLASSPATH%

 

Tetapi apabila anda memakai Windows 7, upaya tersebut gagal karena tidak mendapat permission. Error message yang keluar: “Access to C:\Program Files\Weka-3-7\RunWeka.ini was denied”. Cara mengatasinya adalah:

  1. Copylah RunWeka.ini ke tempat lain selain di bawah C:\Program Files. Misalnya kalau di PC saya, file dicopy ke folder C:\Users\Anto Satriyo Nugroho\Documents
  2. Selanjutnya editlah nilai heapsize sebagaimana yang diinginkan
  3. Copylah file yang telah diedit ke folder semula. Dalam hal ini anda akan diminta melakukannya dengan login sebagai Administrator.

Happy Weka !

Iklan

Tentang Anto Satriyo Nugroho

My name is Anto Satriyo Nugroho. I am working as research scientist at Center for Information & Communication Technology, Agency for the Assessment & Application of Technology (PTIK-BPPT : Pusat Teknologi Informasi & Komunikasi, Badan Pengkajian dan Penerapan Teknologi). I obtained my doctoral degree (Dr.Eng) from Nagoya Institute of Technology, Japan in 2003. My office is located in Serpong, Tangerang Selatan City. My research is on pattern recognition and image processing with applied field of interests on biometrics identification & development of computer aided diagnosis for Malaria. Should you want to know further information on my academic works, please visit my professional site at http://asnugroho.net
Pos ini dipublikasikan di datamining. Tandai permalink.

Tinggalkan Balasan

Isikan data di bawah atau klik salah satu ikon untuk log in:

Logo WordPress.com

You are commenting using your WordPress.com account. Logout / Ubah )

Gambar Twitter

You are commenting using your Twitter account. Logout / Ubah )

Foto Facebook

You are commenting using your Facebook account. Logout / Ubah )

Foto Google+

You are commenting using your Google+ account. Logout / Ubah )

Connecting to %s