Skip to content

Commit

Permalink
minor bugfix in cholla frontend
Browse files Browse the repository at this point in the history
Previously, the ``domain_right_edge`` attribute of ``ChollaDataset`` was
initialized by assigning it the values of the ``"domain"`` attribute
stored in the hdf5 file. This patch adjusts the logic so that the
``domain_right_edge`` attribute is now the sum of that array and the
array stored in the ``domain_left_edge`` attribute.
  • Loading branch information
mabruzzo committed Oct 5, 2023
1 parent 395f74d commit 1fcdace
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion yt/frontends/cholla/data_structures.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ def _parse_parameter_file(self):
attrs = h5f.attrs
self.parameters = dict(attrs.items())
self.domain_left_edge = attrs["bounds"][:].astype("=f8")
self.domain_right_edge = attrs["domain"][:].astype("=f8")
self.domain_right_edge = self.domain_left_edge + attrs["domain"][:].astype("=f8")
self.dimensionality = len(attrs["dims"][:])
self.domain_dimensions = attrs["dims"][:].astype("=f8")
self.current_time = attrs["t"][:]
Expand Down

0 comments on commit 1fcdace

Please sign in to comment.