I have succeeded in volume rendering regions around some galaxies with the transpose=false fix. But, occasionally, for some reason, the exact same piece of yt code on some galaxies failed with the following error:
AttributeError: 'NoneType' object has no attribute 'id' Building kd-Tree 0% | | ETA: --:--:-- ^MTraceback (most recent call last): File "test.py", line 318, in <module> le=c-0.5*WW, re=c+0.5*WW) File "/u/jhwise/local/lib/python2.7/site-packages/yt-2.4-py2.7-linux-x86_64.egg/yt/utilities/amr_kdtree/amr_kdtree.py", line 376, in __init__ self._build(root_grids, None, self.domain_left_edge, self.domain_right_edge) File "/u/jhwise/local/lib/python2.7/site-packages/yt-2.4-py2.7-linux-x86_64.egg/yt/utilities/amr_kdtree/amr_kdtree.py", line 1059, in _build set_leaf(current_node, current_node.parent_grid, current_node.l_corner, current_node.r_corner) File "/u/jhwise/local/lib/python2.7/site-packages/yt-2.4-py2.7-linux-x86_64.egg/yt/utilities/amr_kdtree/amr_kdtree.py", line 154, in set_leaf thisnode.grid = grid_id.id AttributeError: 'NoneType' object has no attribute 'id'
I am not sure what is causing this.
Thanks very much, Renyue
On Jan 8, 2013, at 12:08 PM, Renyue Cen wrote:
your transpose fix DOES change things and it indeed may working now. Here is the first images I got for comparison. I am going to make a few more pictures to see if things are all good. Thanks very much, <test1.png><test2.png> Best, Renyue
On Jan 8, 2013, at 11:25 AM, Sam Skillman wrote:
I have actually seen this on one other system but I could never reproduce it. Could you tell me the version of yt you are using? If you run "yt instinfo" it should tell you. I haven't seen this bug for the last few months so I thought it was gone.
Additionally, can you try the following at the end of your script:
im=cam.snapshot('test1.png') write_bitmap(im, 'test2.png', transpose=False)
I think there may have been something wrong with the transposing of the image for a short time period a few months ago. I have very sporadic and unreliable internet at AAS but I'll try to respond as quickly as possible.
Sorry for the trouble,
On Jan 7, 2013 10:11 AM, "Renyue Cen" firstname.lastname@example.org wrote: Hi,
I did some simple volume rendering with the following script:
volume2 = AMRKDTree(pf, fields=["Dark_Matter_Density"], no_ghost=False, tree_type="domain", le=c-0.5*WW, re=c+0.5*WW) cam = pf.h.camera(c, L, W, N, tf, volume=volume2, no_ghost=False, north_vector=L, steady_north=True) cam.snapshot(fn="%s_iso-DMdensity-%3.3d.png" % (filenameTHIS, j))
I got rather strange results in that the pictures look symmetric, which I am pretty sure can not be true. I attach the obtained plot. Note that I am using KD tree and using 32 cores.
Your help at your earliest convenience is appreciated. Best, Renyue