IGV extremely slow on 2.2.1

1,429 views
Skip to first unread message

Simon

unread,
Jan 7, 2013, 11:21:24 PM1/7/13
to igv-...@googlegroups.com
Hello all,

I'm running IGV to look at BAM files from exome data - usually 3 individuals in a family. On 2.1.x I can easily look at 3 individuals together.  On 2.2.x the whole interface is so slow I can hardly use it (many seconds to respond to each interaction). I'm doing it on Linux (64-bit) with loads of memory and available CPU - and I can run the old version side by side and get much better performance.

Is this a known / expected problem, or is there perhaps a workaround to get the old performance back?

I really want to use the new version but for now I am stuck with the old one because the new one performs too badly to use with my data. I'm happy to provide any further information or do some profiling if it is useful.

Thanks for any help!

Simon

Jim Robinson

unread,
Jan 8, 2013, 11:34:33 AM1/8/13
to igv-...@googlegroups.com
Hi Simon,

This is not a know problem,  I just tried with 3 thousand-genome bams and don't see any difference.    Since you probably can't send me your BAMs could you see if you can replicate the issue with our hosted 1kg bams (hg18).    To find them select "File > Load from server..." then navigate as shown in the screenshot.   If you can replicate it with these it will be easier for us to debug.

Jim
Screen Shot 2013-01-08 at 11.32.35 AM.png

Simon

unread,
Jan 8, 2013, 6:31:20 PM1/8/13
to igv-...@googlegroups.com
Hi Jim,

Thanks for you reply.

Since it's not a known problem I did a bit more investigation. I tried the files you mentioned below and they were indeed extremely slow as well (ie. the problem reproduces there).

1) I'm using IGV remotely with X11 from a Mac (X-server is on the Mac).
2) The same Mac does not reproduce the problem running IGV locally (ie. it's fast, on exactly the same data)
3) I updated from OpenJDK Java 1.6 to Sun JDK 1.7 - no change
4) I did some quick profiling with VisualVM. I've attached screen shots of the hot spots for 2.2.1 and 2.1.24. You can see really clearly that AlignmentRenderer.drawAlignment() has gone from negligible to extremely CPU intensive. Perhaps someone can have a look at what changed here? I can send you a full snapshot from the profiler if that would be helpful.

2.2.1:

2.1.24:

Cheers / Thanks!

Simon

Jim Robinson

unread,
Jan 8, 2013, 9:51:35 PM1/8/13
to igv-...@googlegroups.com
Hi Simon,

Thanks for the analysis.  I assume these profiles are from a run over x-windows?  I cannot replicate this result here,  alignment drawing isn't even in the top 50.   If you could send your full profile file to igv-...@broadinstitute.org we will have a look, if we can read it.  We use jprofiler here.

I'm surprised that you were able to get anything like good performance over x-windows for any version of IGV.   I consider it to graphical and interactive to work well over x-windows.  If at all possible I suggest you try using a vncserver instead.

-- Jim

Jim Robinson

unread,
Jan 8, 2013, 9:51:50 PM1/8/13
to igv-...@googlegroups.com

Simon

unread,
Jan 10, 2013, 1:27:22 AM1/10/13
to igv-...@googlegroups.com
Hi Jim,

On Wednesday, January 9, 2013 1:51:35 PM UTC+11, Jim Robinson wrote:

Thanks for the analysis.  I assume these profiles are from a run over x-windows?  I cannot replicate this result here,  alignment drawing isn't even in the top 50.   If you could send your full profile file to igv-...@broadinstitute.org we will have a look, if we can read it.  We use jprofiler here.

I've exported a snapshot from the profiler so you could have a look (attached). It's created using VisualVM on the Linux server (ie. remotely) where IGV is running and rendering over X11 to my Mac. I'm not sure if jprofiler can read it or not, but you can open it with jvisualvm (comes with Oracle JDK) to look at it.
 
It seems like it's ultimately spending all its time inside SunGraphics2D doing drawing operations, which is what you would expect, but the are just taking much, much longer, and it's all CPU time. It's also happening across the board in every view that's rendered. I looked at the diff between 2.1.24 and 2.2.3 and there don't seem to be any significant changes to the drawing code itself that would cause this. I'm wondering if something other change has made all the drawing operations more expensive (flipped them from accelerated to non-accelerated, etc.) - any changes to the bit depth, quality, anti-aliasing settings etc?  Just curious.

I'm surprised that you were able to get anything like good performance over x-windows for any version of IGV.   I consider it to graphical and interactive to work well over x-windows.  If at all possible I suggest you try using a vncserver instead.
 
Actually it works really well over X11 in the older versions, nearly like native with a server inside our office, but even with a server on a different network it is (was) very usable. VNC would be an interesting experiment (since it would still be X11, but not over a networ). But I'd rather use X11 directly if I can.

Thanks again for any help, I intend to look more at it myself as well (since I kind of need it to work!), but I'm strongly suspecting it's some kind of incidental change that's affected the Java X11 implementation rather than an actual code change now.

Cheers,

Simon
igv_2.2.3_slow.nps.zip

Jim Robinson

unread,
Jan 10, 2013, 8:24:24 AM1/10/13
to igv-...@googlegroups.com
Hi Simon,

I think you got it,  anti-aliasing has been turned on everywhere,  without it fonts look awful in Java 7 on a Mac.  Also, there is a bug affecting rotated text in Java 7 which anti-aliasing bizarrely fixes.

I can add an option to turn this off,  but first since you have the problem can you confirm that it will fix it?  Search for settings of the anti-aliasing hint and turn it off,  or just turn it off in the DataPanel.   I warn you there are a lot of these,  we found that the global hint was being ignored (at least with Java 7 on a Mac).

Jim


--
 
 
 

Simon

unread,
Jan 10, 2013, 7:50:34 PM1/10/13
to igv-...@googlegroups.com

On Friday, January 11, 2013 12:24:24 AM UTC+11, Jim Robinson wrote:

I think you got it,  anti-aliasing has been turned on everywhere,  without it fonts look awful in Java 7 on a Mac.  Also, there is a bug affecting rotated text in Java 7 which anti-aliasing bizarrely fixes.

Aha - that all makes sense - awesome!
 
I can add an option to turn this off,  but first since you have the problem can you confirm that it will fix it?  Search for settings of the anti-aliasing hint and turn it off,  or just turn it off in the DataPanel.   I warn you there are a lot of these,  we found that the global hint was being ignored (at least with Java 7 on a Mac).

No problem - I will try this out. Won't be for a few days since I'm out of the office, but I will report back next week.

Thanks again!

Cheers,

Simon

Simon

unread,
Jan 13, 2013, 8:56:40 PM1/13/13
to igv-...@googlegroups.com
Hi Jim,

I got a chance to try out a modified IGV today with the anti-aliasing turned off and I can confirm it's back to its original performance.

It would be great to have a preference for this. I don't know if it would be useful, but I'm attaching a patch for the code changes I made. They enable it to be controlled by setting a system property at startup, like so:

java -Xmx1g -Digv.antialias=false -jar igv.jar

Thanks!

Simon
antialiasing.patch

Steve Lianoglou

unread,
Jan 19, 2013, 5:04:33 PM1/19/13
to igv-...@googlegroups.com
Howdy,

It'd be very helpful if something along these lines would make its way
back into IGV -- I've also noticed that IGV has taken a serious
performance hit on on my mac(s), as well ...

Thanks for smoking this problem out, folks!

-steve
> --
>
>
>



--
Steve Lianoglou
Graduate Student: Computational Systems Biology
| Memorial Sloan-Kettering Cancer Center
| Weill Medical College of Cornell University
Contact Info: http://cbio.mskcc.org/~lianos/contact

Jim Robinson

unread,
Jan 19, 2013, 5:18:47 PM1/19/13
to igv-...@googlegroups.com
Hi,

I've added this (disabling anti-aliasing) as a user preference in the
latest point release.

We develop on Macs and use IGV extensively here, at the moment we are
not aware of any performance issues other than this x-windows
problem. If you are aware of other issues please give us details,
its very helpful if you can reproduce them with datasets we host (i.e.
"load from server").

Thanks

Jim

Simon

unread,
Jan 20, 2013, 5:18:13 PM1/20/13
to igv-...@googlegroups.com


On Sunday, January 20, 2013 9:18:47 AM UTC+11, Jim Robinson wrote:
Hi,

I've added this (disabling anti-aliasing) as a user preference in the
latest point release.

Thanks Jim!
 
We develop on Macs and use IGV extensively here, at the moment we are
not aware of any performance issues other than this x-windows
problem.

I'm guessing that it's highly dependent on whether the Java2D rendering pipeline decides it can use hardware accelerated rendering for the anti-aliased graphics. I'm not sure what would affect that, but I could see it depending on the version of java used, the exact graphics chip, the drivers, etc.  So it's great to have an option to turn it off and fall back to "simple" graphics.

Cheers,

Simon

Jim Robinson

unread,
Jan 20, 2013, 5:52:09 PM1/20/13
to igv-...@googlegroups.com
I suspect you are right.  There are a number of  "hints" that can be provided for Mac performance, we had it tuned pretty well for pre Java 7 (Apple VMs) following Apple's recommendations,  but probably should revisit it now.

Jim
--
 
 
 

Reply all
Reply to author
Forward
0 new messages