spux.drivers package


spux.drivers.java module

class spux.drivers.java.Java(jvmpath=None, classpath=None, jvmargs='', cwrank=-1)[source]

Bases: object

Convenience wrapper for Python Java bindings.

WARNING: due to underlying Python Java bindings library limitations, you cannot run a single Python process that uses this driver at least twice but with different Java classpaths. The subsequent classpaths won’t correctly load.


Return the java class ‘name’ from loaded java jar

jpype = None
classmethod load(state)[source]

Take ‘state’ (of the model) from save(), i.e. as numpy uint8 array, and return ‘buff’ in byte to be passed to the java user code

classmethod save(buff)[source]

Return ‘state’ (of the model) as numpy uint8 array when ‘buff’ (the state of the model from the user code) is in binary format

started_in = {}
classmethod state(size)[source]

Return ‘state’ as jByteArray of given ‘size’