Skip to content

Commit

Permalink
add JVM memory input
Browse files Browse the repository at this point in the history
  • Loading branch information
Lawhy committed Feb 10, 2023
1 parent b32b1b1 commit de20f01
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/deeponto/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,5 @@ def init_jvm(memory):
convertStrings=False)

if jpype.isJVMStarted():
print(f"{memory} maximum memory allocated to JVM.")
print("JVM started successfully.")
5 changes: 4 additions & 1 deletion src/deeponto/onto/ontology.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,10 @@
from deeponto import init_jvm

# initialise JVM for python-java interaction
init_jvm("2g")
import click
memory = click.prompt("Please enter the maximum memory located to JVM", type=str, default="8g")
print()
init_jvm(memory)

from java.io import File # type: ignore
from java.util import Collections # type: ignore
Expand Down

0 comments on commit de20f01

Please sign in to comment.