stevekm/IGV-snapshot-automator

testing run is not working

yinshiyi opened this issue · 5 comments

(base) shiyi@ip-192-168-1-231:~/mnt/atac-fetal-2021-11/IGV-snapshot-automator$ python make_IGV_snapshots.py test_data/test_alignments.bam test_data/test_alignments2.bam


Reference genome:
hg19

Track height:
500

IGV binary file:
/home/shiyi/mnt/atac-fetal-2021-11/IGV-snapshot-automator/igv.jar

Output directory will be:
/home/shiyi/mnt/atac-fetal-2021-11/IGV-snapshot-automator/IGV_Snapshots

Batchscript file will be:
/home/shiyi/mnt/atac-fetal-2021-11/IGV-snapshot-automator/IGV_Snapshots/IGV_snapshots.bat

Region file:
/home/shiyi/mnt/atac-fetal-2021-11/IGV-snapshot-automator/regions.bed

Input files to snapshot:

test_data/test_alignments.bam
test_data/test_alignments2.bam

Making the output directory...

Writing IGV batch script to file:
/home/shiyi/mnt/atac-fetal-2021-11/IGV-snapshot-automator/IGV_Snapshots/IGV_snapshots.bat


Getting regions from BED file...

Read 4 regions
xdpyinfo:  unable to open display ":1".

Open Xvfb port found on:
1


IGV command is:
xvfb-run --auto-servernum --server-num=1 java -Xmx4000m -jar /home/shiyi/mnt/atac-fetal-2021-11/IGV-snapshot-automator/igv.jar -b /home/shiyi/mnt/atac-fetal-2021-11/IGV-snapshot-automator/IGV_Snapshots/IGV_snapshots.bat


Current time is:
2022-01-10 18:43:33.046202


Running the IGV command...
/bin/sh: 1: xvfb-run: not found
b''

IGV finished; elapsed time is:
0:00:00.001256

(base) shiyi@ip-192-168-1-231:~/mnt/atac-fetal-2021-11/IGV-snapshot-automator$ 





i am not seeing any snapshot saved in the directory, do you know what can be the problem?
thank you

update
I fixed the xvfb-run

(base) shiyi@ip-192-168-1-231:~/mnt/atac-fetal-2021-11/IGV-snapshot-automator$ xvfb-run --auto-servernum --server-num=1 java -Xmx4000m -jar /home/shiyi/mnt/atac-fetal-2021-11/IGV-snapshot-automator/igv.jar -b /home/shiyi/mnt/atac-fetal-2021-11/IGV-snapshot-automator/IGV_Snapshots/IGV_snapshots.bat
WARN [2022-01-12 16:18:47,560] [Globals.java:138] [AWT-EventQueue-0] Development mode is enabled
INFO [2022-01-12 16:18:47,593] [DirectoryManager.java:171] [AWT-EventQueue-0] IGV Directory: /home/shiyi/igv
INFO [2022-01-12 16:18:47,593] [DirectoryManager.java:171] IGV Directory: /home/shiyi/igv
INFO [2022-01-12 16:18:47,595] [Main.java:154] [AWT-EventQueue-0] Startup IGV Version 2.4.10 03/20/2018 10:50 PM
INFO [2022-01-12 16:18:47,596] [Main.java:155] [AWT-EventQueue-0] Java 11.0.13
INFO [2022-01-12 16:18:47,596] [DirectoryManager.java:76] [AWT-EventQueue-0] Fetching user directory...
INFO [2022-01-12 16:18:47,633] [Main.java:156] [AWT-EventQueue-0] Default User Directory: /home/shiyi
INFO [2022-01-12 16:18:47,633] [Main.java:157] [AWT-EventQueue-0] OS: Linux

Jan 12, 2022 4:18:47 PM java.util.prefs.FileSystemPreferences$6 run
WARNING: Prefs file removed in background /home/shiyi/.java/.userPrefs/prefs.xml
INFO [2022-01-12 16:18:47,989] [Main.java:202] [Thread-2] A later version of IGV is available (2.10.2)
ERROR [2022-01-12 16:18:51,699] [DefaultExceptionHandler.java:49] [AWT-EventQueue-0] Unhandled exception
java.lang.NoClassDefFoundError: javax/xml/bind/JAXBException
at org.broad.igv.ui.IGVMenuBar.refreshToolsMenu(IGVMenuBar.java:275)
at org.broad.igv.ui.IGVMenuBar.createMenus(IGVMenuBar.java:185)
at org.broad.igv.ui.IGVMenuBar.(IGVMenuBar.java:155)
at org.broad.igv.ui.IGVMenuBar.lambda$createInstance$1(IGVMenuBar.java:142)
at org.broad.igv.ui.util.UIUtilities.invokeAndWaitOnEventThread(UIUtilities.java:166)
at org.broad.igv.ui.IGVMenuBar.createInstance(IGVMenuBar.java:142)
at org.broad.igv.ui.IGV.(IGV.java:261)
at org.broad.igv.ui.IGV.createInstance(IGV.java:162)
at org.broad.igv.ui.Main.open(Main.java:284)
at org.broad.igv.ui.Main$1.run(Main.java:108)
at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:313)
at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:770)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:740)
at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)
Caused by: java.lang.ClassNotFoundException: javax.xml.bind.JAXBException
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:581)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522)
... 23 more

Now

update I fixed the xvfb-run

(base) shiyi@ip-192-168-1-231:~/mnt/atac-fetal-2021-11/IGV-snapshot-automator$ xvfb-run --auto-servernum --server-num=1 java -Xmx4000m -jar /home/shiyi/mnt/atac-fetal-2021-11/IGV-snapshot-automator/igv.jar -b /home/shiyi/mnt/atac-fetal-2021-11/IGV-snapshot-automator/IGV_Snapshots/IGV_snapshots.bat WARN [2022-01-12 16:18:47,560] [Globals.java:138] [AWT-EventQueue-0] Development mode is enabled INFO [2022-01-12 16:18:47,593] [DirectoryManager.java:171] [AWT-EventQueue-0] IGV Directory: /home/shiyi/igv INFO [2022-01-12 16:18:47,593] [DirectoryManager.java:171] IGV Directory: /home/shiyi/igv INFO [2022-01-12 16:18:47,595] [Main.java:154] [AWT-EventQueue-0] Startup IGV Version 2.4.10 03/20/2018 10:50 PM INFO [2022-01-12 16:18:47,596] [Main.java:155] [AWT-EventQueue-0] Java 11.0.13 INFO [2022-01-12 16:18:47,596] [DirectoryManager.java:76] [AWT-EventQueue-0] Fetching user directory... INFO [2022-01-12 16:18:47,633] [Main.java:156] [AWT-EventQueue-0] Default User Directory: /home/shiyi INFO [2022-01-12 16:18:47,633] [Main.java:157] [AWT-EventQueue-0] OS: Linux

now getting a different error code

Jan 12, 2022 4:18:47 PM java.util.prefs.FileSystemPreferences$6 run WARNING: Prefs file removed in background /home/shiyi/.java/.userPrefs/prefs.xml INFO [2022-01-12 16:18:47,989] [Main.java:202] [Thread-2] A later version of IGV is available (2.10.2) ERROR [2022-01-12 16:18:51,699] [DefaultExceptionHandler.java:49] [AWT-EventQueue-0] Unhandled exception java.lang.NoClassDefFoundError: javax/xml/bind/JAXBException at org.broad.igv.ui.IGVMenuBar.refreshToolsMenu(IGVMenuBar.java:275) at org.broad.igv.ui.IGVMenuBar.createMenus(IGVMenuBar.java:185) at org.broad.igv.ui.IGVMenuBar.(IGVMenuBar.java:155) at org.broad.igv.ui.IGVMenuBar.lambda$createInstance$1(IGVMenuBar.java:142) at org.broad.igv.ui.util.UIUtilities.invokeAndWaitOnEventThread(UIUtilities.java:166) at org.broad.igv.ui.IGVMenuBar.createInstance(IGVMenuBar.java:142) at org.broad.igv.ui.IGV.(IGV.java:261) at org.broad.igv.ui.IGV.createInstance(IGV.java:162) at org.broad.igv.ui.Main.open(Main.java:284) at org.broad.igv.ui.Main$1.run(Main.java:108) at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:313) at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:770) at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721) at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715) at java.base/java.security.AccessController.doPrivileged(Native Method) at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85) at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:740) at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203) at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124) at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113) at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109) at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101) at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90) Caused by: java.lang.ClassNotFoundException: javax.xml.bind.JAXBException at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:581) at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178) at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522) ... 23 more

Hey sorry for not replying earlier, as you likely figured out the xvfb-run program is a platform-specific wrapper script that is usually installed automatically when you install xvfb.

As for your other error, I'm not sure, it appears to be an issue with IGV itself via Java. Not sure how you installed IGV and Java in your system. But you might want to try using the included Docker container instead.

As per the README the Docker container is hosted here
https://hub.docker.com/r/stevekm/igv-snapshot-automator

You can pull it with the following command

docker pull stevekm/igv-snapshot-automator

closing this one, let me know if you cannot get it to work using the Docker container, thanks