[yt-dev] Issue #1319: fields as contiguous arrays for idealized galaxies (yt_analysis/yt)
Desika Narayanan
issues-reply at bitbucket.org
Tue Feb 7 08:18:48 PST 2017
New issue 1319: fields as contiguous arrays for idealized galaxies
https://bitbucket.org/yt_analysis/yt/issues/1319/fields-as-contiguous-arrays-for-idealized
Desika Narayanan:
This is related to a previous bugfix: https://bitbucket.org/yt_analysis/yt/pull-requests/2498/ensure-fields-are-contiguous-arrays-before/diff
If I try a related test with an idealized gadget galaxy (a test snapshot can be found here:
https://www.dropbox.com/s/q817i6w6wpb42we/snapshot_050.hdf5?dl=0
with the following code:
http://paste.yt-project.org/show/7015/
it returns an error similar to PR 2498:
```
jam:scratch desika$ python vel_proj_idealized.py
yt : [INFO ] 2017-02-07 11:14:47,621 Omega Lambda is 0.0, so we are turning off Cosmology.
yt : [INFO ] 2017-02-07 11:14:47,630 Parameters: current_time = 0.25
yt : [INFO ] 2017-02-07 11:14:47,630 Parameters: domain_dimensions = [2 2 2]
yt : [INFO ] 2017-02-07 11:14:47,631 Parameters: domain_left_edge = [-1000. -1000. -1000.]
yt : [INFO ] 2017-02-07 11:14:47,631 Parameters: domain_right_edge = [ 1000. 1000. 1000.]
yt : [INFO ] 2017-02-07 11:14:47,632 Parameters: cosmological_simulation = 0
yt : [INFO ] 2017-02-07 11:14:47,634 Allocating for 2.515e+07 particles (index particle type 'all')
yt : [INFO ] 2017-02-07 11:14:51,665 Identified 1.540e+06 octs
[ 0. 0. 0. ..., 0. 0. 0.] code_velocity
Traceback (most recent call last):
File "vel_proj_idealized.py", line 23, in <module>
vy = arb[ ('deposit', 'PartType0_sum_velocity_y')]
File "/Users/desika/yt/yt/data_objects/data_containers.py", line 281, in __getitem__
self.get_data(f)
File "/Users/desika/yt/yt/data_objects/construction_data_containers.py", line 635, in get_data
if len(gen) > 0: self._generate_fields(gen)
File "/Users/desika/yt/yt/data_objects/data_containers.py", line 1353, in _generate_fields
fd = self._generate_field(field)
File "/Users/desika/yt/yt/data_objects/data_containers.py", line 318, in _generate_field
tr = self._generate_fluid_field(field)
File "/Users/desika/yt/yt/data_objects/data_containers.py", line 338, in _generate_fluid_field
rv = finfo(gen_obj)
File "/Users/desika/yt/yt/fields/derived_field.py", line 220, in __call__
dd = self._function(self, data)
File "/Users/desika/yt/yt/data_objects/static_output.py", line 1260, in _deposit_field
method=method, kernel_name=kernel_name),
File "/Users/desika/yt/yt/data_objects/construction_data_containers.py", line 728, in deposit
op.process_grid(self, positions, fields)
File "yt/geometry/particle_deposit.pyx", line 120, in yt.geometry.particle_deposit.ParticleDepositOperation.process_grid (yt/geometry/particle_deposit.c:5181)
ValueError: Buffer and memoryview are not contiguous in the same dimension.
```
More information about the yt-dev
mailing list