Opened 6 years ago
Last modified 6 years ago
#2832 assigned defect
Chain trace creation delayed in scripts
Reported by: | Owned by: | Tom Goddard | |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | Structure Analysis | Version: | |
Keywords: | Cc: | Elaine Meng, pett | |
Blocked By: | Blocking: | ||
Notify when closed: | Platform: | all | |
Project: | ChimeraX |
Description
The following bug report has been submitted: Platform: Darwin-19.3.0-x86_64-i386-64bit ChimeraX Version: 0.92 (2020-02-05) Description Loading the attached script does not hide the one chain trace pseudobond as expected. But running the commands individually does hide it. The trouble is that the chain trace is not created until the graphics is updated. That happens during the view command (to determine scene bounds is does a graphics update, ribbon bounds are not correct without this), and at the end of the script. Log: Startup Messages --- warning | 'clip' is a prefix of an existing command 'clipper' UCSF ChimeraX version: 0.92 (2020-02-05) © 2016-2020 Regents of the University of California. All rights reserved. How to cite UCSF ChimeraX > open /Users/goddard/Downloads/thr.cxc > open 3gws 3gws title: Crystal Structure of T3-Bound Thyroid Hormone Receptor [more info...] Chain information for 3gws #1 --- Chain | Description X | Thyroid hormone receptor β Non-standard residues in 3gws #1 --- T3 — 3,5,3'triiodothyronine (T3; thyroid hormone; liothyronine) > hide solvent > label :331,346,282,t3 > hide cartoons > hide @n,c,o > style @ca ball Changed 246 atom styles > hide pseudobonds > set bgColor white > graphics silhouettes true > view > color ligand & C green > swapaa interactive :331 his > swapaa interactive :346 arg > transparency #1.4,1.5 50 target a > size #1.4,1.5 stickRadius .1 Changed 8 bond radii executed thr.cxc > color #1.3 red > usage style style [objects] [atomStyle] [dashes an integer] [ringFill ringFill] — change atom and bond depiction objects: an objects specifier or nothing atomStyle: one of ball, sphere, or stick or nothing ringFill: one of off, on, thick, or thin > usage show show [objects] [what] [target object type] — show specified objects objects: an objects specifier or nothing what: a collection of one of atoms, bonds, cartoons, models, pbonds, pseudobonds, ribbons, or surfaces > usage color color [objects] [color [what]] [target characters from 'abcfprs'] [transparency a number] [halfbond true or false] — color objects objects: an objects specifier or nothing color: a color or one of byatom, bychain, byelement, byhetero, bymodel, bynucleotide, bypolymer, fromatoms, or random what: a collection of one of All, atoms, bonds, cartoons, labels, pseudobonds, ribbons, rings, or surfaces Subcommands are: * color bfactor * color byattribute * color cylindrical * color delete * color electrostatic * color gradient * color height * color list * color modify * color name * color radial * color sample * color sequential * color show * color zone > color #1.3 red halfbond false OpenGL version: 4.1 ATI-3.5.5 OpenGL renderer: AMD Radeon Pro 580 OpenGL Engine OpenGL vendor: ATI Technologies Inc. File attachment: thr.cxc
Attachments (1)
Change History (3)
by , 6 years ago
comment:1 by , 6 years ago
Cc: | added |
---|---|
Component: | Unassigned → Structure Analysis |
Owner: | set to |
Platform: | → all |
Project: | → ChimeraX |
Status: | new → assigned |
Summary: | ChimeraX bug report submission → Chain trace creation delayed in scripts |
Hiding backbone atoms except CA makes a chain trace when the next graphics update (rendering) occurs. If you execute a command to act on that chain trace before that graphics update for example to hide the chain trace it does nothing since the chain trace does not exist yet.
No obvious way to fix this and maintain decent performance and code complexity.
Only happens in a script when graphics is not drawn between commands.
Reported originally by Elaine.
comment:2 by , 6 years ago
Can add a "wait 1" command to script to get it to work, although no one will figure that out.
Begin forwarded message:
From: Tom Goddard
Subject: Re: rotamers display
Date: February 11, 2020 at 4:46:41 PM PST
To: Elaine Meng
Cc: Eric Pettersen
Hi Elaine,
Eric redirected the mysterious hide pseudobond problem in your command script to me. The trouble is that the chain trace pseudobonds are only created when a graphics update occurs, which is when a wait command is executed or it reaches the end of the script and the graphics is drawn. So there are no chain trace pseudobonds to hide when your script does "hide pseudobonds" after "style @ca ball". Surprisingly it does work after the "view" command because it turns out that the view command does a graphics update (although no graphics are rendered). It does this because things like ribbons don't get computed until a graphics update and "view" won't get the bounds right unless the ribbon has been computed, so it triggers a graphics update.
At any rate, this is pretty bad behavior. But I don't have any suggestion for how to make it work better. The trouble is that the code doesn't know when to look for the appearance of a chain trace -- any old Python could be hiding and showing atoms that triggers a chain trace. So its current behavior is to decide to make a chain trace when it updates the graphics.
Another case of the same kind of problem is if you change a volume surface level (volume #1 level .5). It does not recompute the surface immediately, instead waits for the next graphics update. So if you follow it with a command to measure the surface area it will not measure the area of the new surface if the graphics has not been drawn.
You might want to make a ticket for this problem to document it, even though we don't have an idea for how to fix it.
Tom
Added by email2trac