From ec4d62ad7b17332ad72001f315e642ade5bfd9ec Mon Sep 17 00:00:00 2001 From: Josh Shields Date: Thu, 22 Aug 2024 14:28:46 -0400 Subject: [PATCH] blackify --- tardis/io/atom_data/base.py | 50 ++++++++++++++++++------------------- 1 file changed, 24 insertions(+), 26 deletions(-) diff --git a/tardis/io/atom_data/base.py b/tardis/io/atom_data/base.py index fa6e1abace0..3f53408a210 100644 --- a/tardis/io/atom_data/base.py +++ b/tardis/io/atom_data/base.py @@ -528,9 +528,9 @@ def prepare_continuum_interaction_data(self, continuum_interaction_species): ) level_idxs2continuum_idx = photo_ion_levels_idx.copy() - level_idxs2continuum_idx["continuum_idx"] = ( - self.level2continuum_edge_idx - ) + level_idxs2continuum_idx[ + "continuum_idx" + ] = self.level2continuum_edge_idx self.level_idxs2continuum_idx = level_idxs2continuum_idx.set_index( ["source_level_idx", "destination_level_idx"] ) @@ -564,33 +564,31 @@ def prepare_macro_atom_data( self.macro_atom_references = self.macro_atom_references.loc[ self.macro_atom_references["count_down"] > 0 ] - self.macro_atom_references.loc[:, "count_total"] = ( - self.macro_atom_references["count_down"] - ) - self.macro_atom_references.loc[:, "block_references"] = ( - np.hstack( - ( - 0, - np.cumsum( - self.macro_atom_references["count_down"].values[ - :-1 - ] - ), - ) + self.macro_atom_references.loc[ + :, "count_total" + ] = self.macro_atom_references["count_down"] + self.macro_atom_references.loc[ + :, "block_references" + ] = np.hstack( + ( + 0, + np.cumsum( + self.macro_atom_references["count_down"].values[:-1] + ), ) ) elif line_interaction_type == "macroatom": - self.macro_atom_references.loc[:, "block_references"] = ( - np.hstack( - ( - 0, - np.cumsum( - self.macro_atom_references[ - "count_total" - ].values[:-1] - ), - ) + self.macro_atom_references.loc[ + :, "block_references" + ] = np.hstack( + ( + 0, + np.cumsum( + self.macro_atom_references["count_total"].values[ + :-1 + ] + ), ) )