Page 1 of 2

jreality doesn't start reliably

Posted: 13 Aug 2015, 21:00
by beew
Hi,

Just installed polymake 2.14 on Ubuntu 15.04 64 bit on two machines.

On one machine (intel graphic), once in a while jreality doesn't start. Running codes like

Code: Select all

$c=cube(3); $c->VISUAL;
usually works but sometimes nothing happens and deleting the file ~/.polymake/pref.pl somehow fixes it and it works normally again.

On the other machine (amd graphic with open source driver) jreality started a few times (but blank, with no image) and then it never starts again.

Starting polymake with

Code: Select all

polymake -dd
shows that it gets stuck at
INFO:could not setup mac os handler, maybe not a mac
Otherwise there was no error.

(just ran this again on the amd machine, this time jreality started, the probability of it starting is about 1/10. But jreality doesn't show any cube)

Re: jreality doesn't start reliably

Posted: 14 Aug 2015, 07:41
by beew
Problem seems to be related to java somehow getting stuck. If jreality doesn't show up killing java and re-running the VISUAL command it may work. I think jreality comes with its own bundled java. I am wondering if there is a way to use the system's java instead of bundled one perhaps by editing customize.pl? I mean precisely what I should put for
$JReality::Viewer::jogl_path and
$JReality::Viewer::jogl_native_path?

Re: jreality doesn't start reliably

Posted: 14 Aug 2015, 10:04
by assarf
We ship jogl binaries but no java. So your polymake uses your system java installation but the jogl libraries bundled with polymake. Since the latest release we updated the jogl version which fixed several visualization bugs (like the empty screen you described).

We are planning on releasing a updated 2.14 version (also with perl 5.22 support). In the meantime you may use/try the perpetual beta version, since those changes are already in there. Check: http://polymake.org/doku.php/perpetualbeta

Re: jreality doesn't start reliably

Posted: 11 Nov 2015, 05:57
by beew
Hi, compiled 2.14r1 on Ubuntu 15.04 and 15.10, it is even worse than 2.14 in that jreality almost never starts.

I am wondering where I can download the source for 2.14?

Thanks.

Posted: 11 Nov 2015, 17:21
by assarf
Weird...

For older sources you may check github. Just checkout the right release.

Re: jreality doesn't start reliably

Posted: 12 Nov 2015, 04:48
by beew
I have tried 2.14, 2.14r1 and the beta, jreality doesn't start with any version for Ubuntu 15.10 64 bit. java appears to be stuck and even "killall java" doesn't kill it, have to do "killall -9 java" to terminate. But I have tested with other java applications and they work without problem.

Polymake was complied against openjdk8. Can that be a problem?

Re: jreality doesn't start reliably

Posted: 12 Nov 2015, 12:33
by blorenz
Polymake was complied against openjdk8. Can that be a problem?
I just rebuild my polymake against a fresh install of openjdk-1.8.0 and jreality works fine, so this should not be the problem.

I think the problem are the jogl libraries, and maybe a rather recent intel graphics? Could you give some more details on your hardware and it might be helpful if you could generate a debug log of a (non-working) java startup by running:

Code: Select all

polymake -dd 2> debug.log
Once the polymake shell appears please run:

Code: Select all

jreality(cube(3)->VISUAL);
Then you can exit polymake and attach the generated debug.log (or send it to lorenz (at) math.tu-berlin.de).

Note that the above needs to be done with polymake 2.14r1 or at least 2.15-beta1, as 2.14 and older versions wont generate the necessary jogl debug output.

Best,
Benjamin

Re: jreality doesn't start reliably

Posted: 13 Nov 2015, 19:24
by beew
Hi, I have attached the debug log for 2.15 beta.

It is intel graphic but hardly recent. The graphic card is ironlake mobile, the laptop is about 5 years old.

Re: jreality doesn't start reliably

Posted: 19 Nov 2015, 20:27
by beew
Hello, anyone out there?

Re: jreality doesn't start reliably

Posted: 20 Nov 2015, 11:27
by blorenz
Hi,

sorry for the delay. The log indicates that the problem is in fact not jogl but a general startup issue of jreality (Also, I have a laptop with the same graphics chip and cant reproduce the problem). In the meantime we have fixed two race conditions in the java/jreality interface which we hope will solve your problems.

I have attached a patch, to apply please change to the polymake source directory and run:

Code: Select all

patch -p0 < /path/to/jreality_fix.diff
Afterwards rerun make (and make install) and try polymake again.

Benjamin