Opened 6 years ago

Closed 6 years ago

#2180 closed defect (fixed)

QTimer not in QThread (offscreen rendering not working)

Reported by: jmsstarlight@… Owned by: Greg Couch
Priority: moderate Milestone:
Component: Graphics Version:
Keywords: Cc: chimera-programmers
Blocked By: Blocking:
Notify when closed: Platform: all
Project: ChimeraX

Description

hello,
just tested with 0.91 version of Chimera-X. There is still a problem
with making of the image while execution of chimeraX in --offscreen
-nogui
(with the same script there is not problems in no gui mode). Here is
the detailed outputs:

INFO:
UCSF ChimeraX version: 0.91 (2019-07-07)
INFO:
© 2016-2019 Regents of the University of California. All rights reserved.
INFO:
[How to cite UCSF ChimeraX](cxcmd:help help:credits.html)

INFO:
Executing: open chimeraX.0062_310K.cxc
INFO:
Executing: open B-factors_0062_310K.pdb
INFO:
Summary of feedback from opening B-factors_0062_310K.pdb
---
_warning_ | Ignored bad PDB record found on line 2
REMARK THIS IS A SIMULATION BOX

INFO:
_B-factors_0062_310K.pdb_ title:
Good gRace! Old Maple Actually Chews Slate more info...(cxcmd:log
metadata #1)

INFO:
Chain information for B-factors_0062_310K.pdb #1
---
Chain | Description
[ ](cxcmd:select :1-219 "Select chain") | [No description
available](cxcmd:sequence chain #1/ "Show sequence")

INFO:
Executing: open florence.pdb
INFO:
Chain information for florence.pdb #2
---
Chain | Description
[ ](cxcmd:select #2:1-219 "Select chain") | [No description
available](cxcmd:sequence chain #2/ "Show sequence")

INFO:
Executing: hide #2 models
INFO:
Executing: mmaker #1 to #2
INFO:
Parameters
---
Chain pairing | bb
Alignment algorithm | Needleman-Wunsch
Similarity matrix | BLOSUM-62
SS fraction | 0.3
Gap open (HH/SS/other) | 18/18/6
Gap extend | 1
SS matrix | | | H | S | O

---

H | 6 | -9 | -6
S | | 6 | -6
O | | | 4
Iteration cutoff | 2

INFO:
Matchmaker florence.pdb, chain (blank) (#2) with
B-factors_0062_310K.pdb, chain (blank) (#1), sequence alignment score

1132.4

STATUS:
Matchmaker florence.pdb, chain (blank) (#2) with
B-factors_0062_310K.pdb, chain (blank) (#1), sequence alignment score

1132.4

STATUS:
RMSD between 193 pruned atom pairs is 0.874 angstroms; (across all 219
pairs: 2.260)
INFO:
RMSD between 193 pruned atom pairs is 0.874 angstroms; (across all 219
pairs: 2.260)
INFO:

INFO:
Executing: close #2
INFO:
Executing: wait 1
INFO:
Executing: dssp #1
INFO:
Executing: view
INFO:
Executing: zoom 1.5
INFO:
Executing: turn x 15
INFO:
Executing: wait 1
INFO:
Executing: preset "overall look" publication
INFO:
Preset expands to these ChimeraX commands:

set bg white
set silhouettes t

INFO:
Executing: set silhouettes true
INFO:
Executing: set silhouetteColor indigo
INFO:
Executing: set silhouetteDepthJump 0.02
INFO:
Executing: color byattribute bfactor palette rainbow range 2,100
INFO:
877 atoms, 219 residues, atom bfactor range 3.49 to 377
STATUS:
877 atoms, 219 residues, atom bfactor range 3.49 to 377
INFO:
Executing: cartoon style width 2.4 thickness 0.50 xsection barbell
INFO:
Executing: distance #1:56@ca #1:152@ca color maroon
INFO:
Distance between LEU 56 CA and ASN 152 CA: 11.674Å
INFO:
Executing: distance #1:56@ca #1:107@ca color "dark green"
INFO:
Distance between LEU 56 CA and ASN 107 CA: 31.617Å
INFO:
Executing: distance style #1 radius 0.088 dashes 12 decimalPlaces 1
INFO:
Executing: 2dlabels create title text "Cluster 0062_310K" color red
font gothic xpos .20 ypos .88 size 40
INFO:
Executing: lighting depthCueStart .4 depthCueEnd .8
INFO:
Executing: lighting full intensity 1.4 shadows true qualityOfShadows finer
INFO:
Executing: save image ./visu_0062_310K.png format png width 600 height
600 supersample 4 transparentBackground false

0.00% done: Initializing core
50.00% done: Initializing bundles
100.00% done: Finished initialization
QObject::startTimer: Timers can only be used with threads started with QThread
Fatal Python error: Segmentation fault

Thread 0x00007fb1866d2700 (most recent call first):

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/threading.py", line

300 in wait

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/threading.py", line

552 in wait

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/threading.py", line

1156 in run

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/threading.py", line

917 in _bootstrap_inner

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/threading.py", line

885 in _bootstrap

Current thread 0x00007fb1abfef700 (most recent call first):

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/graphics/drawing.py",

line 2058 in text_image_rgba

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/label/label3d.py",

line 625 in _label_image

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/label/label3d.py",

line 427 in <listcomp>

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/label/label3d.py",

line 427 in _packed_texture

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/label/label3d.py",

line 409 in _rebuild_label_graphics

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/label/label3d.py",

line 401 in _update_graphics_if_needed

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/triggerset.py",

line 130 in invoke

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/triggerset.py",

line 190 in activate

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/triggerset.py",

line 325 in activate_trigger

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/graphics/view.py",

line 258 in check_for_drawing_change

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/updateloop.py",

line 64 in draw_new_frame

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/updateloop.py",

line 139 in update_graphics_now

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/commands/save.py",

line 56 in save

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/commands/cli.py",

line 2646 in run

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/commands/run.py",

line 31 in run

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/scripting.py",

line 147 in open_command_script

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/io.py",

line 433 in open_data

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/io.py",

line 479 in open_multiple_data

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/models.py",

line 616 in open

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/commands/open.py",

line 68 in open

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/commands/cli.py",

line 2646 in run

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/chimerax/core/commands/run.py",

line 31 in run

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/ChimeraX_main.py",

line 729 in init

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/site-packages/ChimeraX_main.py",

line 869 in <module>

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/runpy.py", line 85

in _run_code

File "/usr/lib/ucsf-chimerax-daily/lib/python3.7/runpy.py", line 193

in _run_module_as_main
Erreur de segmentation (core dumped)

пт, 28 июн. 2019 г. в 10:51, James Starlight <jmsstarlight@…>:

P.S. sorry I forgot to mention that I have not yet updated Chimera-X
since the version which had been installed at first time. So I will
now do it today and will report the result!

J.

пт, 28 июн. 2019 г. в 10:44, James Starlight <jmsstarlight@…>:

Hi Greg,

sorry for some delay :-)

Actually I just checked and indeed, there is still problem with
rendering of the images with chimera-X using

here is the detailed output if it would help

chimerax-daily --offscreen --nogui "${output}/!temp/chimeraX.${pdb_name}.cxc"

INFO:
Offscreen rendering is not available.
INFO:
module 'OpenGL.osmesa' has no attribute 'OSMESA_DEPTH_BITS'
INFO:
UCSF ChimeraX version: 0.9 (2019-04-03)
INFO:
© 2016-2019 Regents of the University of California. All rights reserved.
INFO:
Executing: open /home_pers/novikov/Bureau/test/test/!temp/chimeraX.0476.cxc
INFO:
Executing: open /home_pers/novikov/Bureau/test/test/!temp/B-factors_0476.pdb
INFO:
Summary of feedback from opening
/home_pers/novikov/Bureau/test/test/!temp/B-factors_0476.pdb
---
_warning_ | Ignored bad PDB record found on line 2
REMARK THIS IS A SIMULATION BOX

INFO:
_B-factors_0476.pdb_ title:
Gallium Rubidium Oxygen Manganese Argon Carbon Silicon
more info...(cxcmd:log metadata #1)

INFO:
Chain information for B-factors_0476.pdb #1
---
Chain | Description
[ ](cxcmd:select :1-219 "Select chain") | [No description
available](cxcmd:sequence chain #1/ "Show sequence")

INFO:
Executing: open /home_pers/novikov/Bureau/test/test/florence.pdb
INFO:
Chain information for florence.pdb #2
---
Chain | Description
[ ](cxcmd:select #2:1-219 "Select chain") | [No description
available](cxcmd:sequence chain #2/ "Show sequence")

INFO:
Executing: mmaker #1 to #2
INFO:
Parameters
---
Chain pairing | bb
Alignment algorithm | Needleman-Wunsch
Similarity matrix | BLOSUM-62
SS fraction | 0.3
Gap open (HH/SS/other) | 18/18/6
Gap extend | 1
SS matrix | | | H | S | O

---

H | 6 | -9 | -6
S | | 6 | -6
O | | | 4
Iteration cutoff | 2

INFO:
Matchmaker florence.pdb, chain (blank) (#2) with B-factors_0476.pdb,
chain (blank) (#1), sequence alignment score = 1131.8
STATUS:
Matchmaker florence.pdb, chain (blank) (#2) with B-factors_0476.pdb,
chain (blank) (#1), sequence alignment score = 1131.8
STATUS:
RMSD between 194 pruned atom pairs is 0.859 angstroms; (across all 219
pairs: 2.266)
INFO:
RMSD between 194 pruned atom pairs is 0.859 angstroms; (across all 219
pairs: 2.266)
INFO:

INFO:
Executing: hide #2 models
INFO:
Executing: wait
ERROR:
wait requires a frame count argument unless motion is in progress
ERROR:
wait requires a frame count argument unless motion is in progress
INFO:
Executing: dssp #1
INFO:
Executing: zoom 1.3
ERROR:
turn x 15 y 15 z -40
ERROR:
..........
ERROR:
Expected an integer >= 1 or a keyword
ERROR:
Expected an integer >= 1 or a keyword
INFO:
Executing: wait
ERROR:
wait requires a frame count argument unless motion is in progress
ERROR:
wait requires a frame count argument unless motion is in progress
INFO:
Executing: preset "'overall look'" publication
INFO:
Preset expands to these ChimeraX commands: _set bg white; set silhouettes t_

INFO:
Executing: set silhouettes true
INFO:
Executing: set silhouetteColor indigo
INFO:
Executing: set silhouetteDepthJump 0.02
INFO:
Executing: color byattribute bfactor palette rainbow range 2,100
INFO:
16875 atoms, 4661 residues, atom bfactor range 0 to 367
STATUS:
16875 atoms, 4661 residues, atom bfactor range 0 to 367
INFO:
Executing: cartoon style width 2.4 thickness 0.50 xsection barbell
INFO:
Executing: 2dlabels create title text '"Cluster 0476"' color red font
gothic xpos .01 ypos .90 size 36
INFO:
Executing: lighting depthCueStart .4 depthCueEnd .8
INFO:
Executing: lighting full intensity 1.4 shadows true qualityOfShadows finer
INFO:
Executing: save image
/home_pers/novikov/Bureau/test/test/!plots/visu_0476.png format png
width 600 height 600 supersample 4 transparentBackground false

and this is my script

open /home_pers/novikov/Bureau/test/test/!temp/B-factors_0472.pdb
open /home_pers/novikov/Bureau/test/test/florence.pdb
mm #1 to #2
hide #2 models
wait
dssp #1
#view
zoom 1.3
turn x 15 y 15 z -40
wait
# options for appearance
preset 'overall look' publication
# set bg powder blue
set silhouettes t; set silhouetteColor indigo; set silhouetteDepthJump 0.02
color byattribute bfactor palette rainbow range 2,100
cartoon style width 2.4 thickness 0.50 xsection barbell

# make info of the screen
2dlab create title text "Cluster 0472" color red font gothic xpos .01
ypos .90 size 36

# options for light
light depthcuestart .4 depthcueend .8; lighting full intensity 1.4
shadows true qualityOfShadows finer

save image /home_pers/novikov/Bureau/test/test/!plots/visu_0472.png
format png width 600 height 600 supersample 4 transparentBackground
false
exit

пн, 22 апр. 2019 г. в 23:38, Greg Couch <gregc@…>:

Salut,

Does ChimeraX work in offscreen mode for you now? I believe it is fixed.

-- Greg

_
ChimeraX-users mailing list
ChimeraX-users@…
Manage subscription:
http://plato.cgl.ucsf.edu/mailman/listinfo/chimerax-users

Change History (5)

comment:1 by pett, 6 years ago

Status: assignedfeedback

Hi James,

It would be helpful if you could supply the script and input files that generate this error. Thanks!

--Eric

Eric Pettersen
UCSF Computer Graphics Lab

comment:2 by Greg Couch, 6 years ago

When ChimeraX --nogui --offscreen starts up, it gets a timer error:

QObject::startTimer: Timers can only be used with threads started with QThread

My guess it that is related to this problem. Will investigate where that is coming from.

comment:3 by Greg Couch, 6 years ago

Maybe QObject::startTimer is not this problem. It might be the old version of llvm, 3.9.1, on CentOS 7 since we're using the system's version mesa-private-llvm-3.9.1-3. While on Ubuntu 18.04, it is using llvm 6.0. Because:

Running "ChimeraX --offscreen 3rec" on Ubuntu 18.04 works. But when it is executed on CentOS 7, it fails with:

*** Error in `chimerax-daily': free(): invalid pointer: 0x00007f5f511a0b20 ***
======= Backtrace: =========
/lib64/libc.so.6(+0x81489)[0x7f5f63d96489]
/lib64/libLLVM-3.9-mesa.so(_ZNSt6locale5_Impl16_M_install_facetEPKNS_2idEPKNS_5facetE+0x142)[0x7f5f50670fa2]
/lib64/libLLVM-3.9-mesa.so(_ZNSt6locale5_ImplC1Em+0x1e3)[0x7f5f50671433]
/lib64/libLLVM-3.9-mesa.so(_ZNSt6locale18_S_initialize_onceEv+0x15)[0x7f5f506723a5]
/lib64/libpthread.so.0(pthread_once+0x50)[0x7f5f638cee40]
/lib64/libLLVM-3.9-mesa.so(_ZNSt6locale13_S_initializeEv+0x21)[0x7f5f506723f1]
/lib64/libLLVM-3.9-mesa.so(_ZNSt6localeC2Ev+0x13)[0x7f5f50672433]
/home/socr/a/chimera/chimerax_daily/lib/python3.7/site-packages/chimerax/atomic/mmcif/_mmcif.cpython-37m-x86_64-linux-gnu.so(+0x5b8dc)[0x7f5f37f858dc]
/home/socr/a/chimera/chimerax_daily/lib/python3.7/site-packages/chimerax/atomic/mmcif/_mmcif.cpython-37m-x86_64-linux-gnu.so(_ZN5mmcif20load_mmCIF_templatesEPKc+0x46)[0x7f5f37f78806]
.... (ots more output) ....
Fatal Python error: Aborted

Current thread 0x00007f5f64852740 (most recent call first):
  File "/home/socr/a/chimera/chimerax_daily/lib/python3.7/site-packages/chimerax/atomic/mmcif/mmcif.py", line 58 in _initialize
  File "/home/socr/a/chimera/chimerax_daily/lib/python3.7/site-packages/chimerax/atomic/mmcif/mmcif.py", line 282 in fetch_mmcif
  File "/home/socr/a/chimera/chimerax_daily/lib/python3.7/site-packages/chimerax/atomic/mmcif/__init__.py", line 46 in fetch_from_database
  File "/home/socr/a/chimera/chimerax_daily/lib/python3.7/site-packages/chimerax/core/toolshed/info.py", line 381 in fetch_shim
  File "/home/socr/a/chimera/chimerax_daily/lib/python3.7/site-packages/chimerax/core/toolshed/info.py", line 383 in fetch_cb
  File "/home/socr/a/chimera/chimerax_daily/lib/python3.7/site-packages/chimerax/core/fetch.py", line 497 in fetch
  File "/home/socr/a/chimera/chimerax_daily/lib/python3.7/site-packages/chimerax/core/fetch.py", line 434 in fetch_from_database
  File "/home/socr/a/chimera/chimerax_daily/lib/python3.7/site-packages/chimerax/core/commands/open.py", line 148 in _fetch_from_database
  File "/home/socr/a/chimera/chimerax_daily/lib/python3.7/site-packages/chimerax/core/commands/open.py", line 44 in open
  File "/home/socr/a/chimera/chimerax_daily/lib/python3.7/site-packages/chimerax/core/commands/cli.py", line 2646 in run
  File "/home/socr/a/chimera/chimerax_daily/lib/python3.7/site-packages/chimerax/core/commands/run.py", line 31 in run
  File "/home/socr/a/chimera/chimerax_daily/lib/python3.7/site-packages/ChimeraX_main.py", line 730 in init
  File "/home/socr/a/chimera/chimerax_daily/lib/python3.7/site-packages/ChimeraX_main.py", line 870 in <module>
  File "/home/socr/a/chimera/chimerax_daily/lib/python3.7/runpy.py", line 85 in _run_code
  File "/home/socr/a/chimera/chimerax_daily/lib/python3.7/runpy.py", line 193 in _run_module_as_main

comment:4 by Greg Couch, 6 years ago

Mysterious. Daily build works if run inside the singularity image that built it. Might be missing a dependency in the rpm. Was testing building against llvm-toolset-7 instead of mesa-private-llvm, and that also works, but we'd need to either include libLLVM.so.5 or add a dependency and explicitly the /opt/rh/llvm-toolset-7/lib version.

comment:5 by Greg Couch, 6 years ago

Resolution: fixed
Status: feedbackclosed

Turns out my problem was due to having LD_LIBRARY_PATH set and a library was inferring with the llvm from mesa-private-llvm.

So I consider this bug fixed. The QTimer problem was fixed. And --offscreen works on CentOS 7 and Ubuntu 18.04.

Note: See TracTickets for help on using tickets.