Skip to content

Commit

Permalink
Fix unresolved reference (#4722)
Browse files Browse the repository at this point in the history
The variable `species` was an unresolved reference and needed to accessed via
`self.species` instead.

Fixed also a word `specie` where `species` was meant.
  • Loading branch information
n01r authored Feb 23, 2024
1 parent daa94bb commit 511fb37
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Python/pywarpx/picmi.py
Original file line number Diff line number Diff line change
Expand Up @@ -2469,7 +2469,7 @@ def diagnostic_initialize_inputs(self):
if self.species is None:
species_names = pywarpx.particles.species_names
elif np.iterable(self.species):
species_names = [specie.name for specie in self.species]
species_names = [species.name for species in self.species]
else:
species_names = [self.species.name]

Expand Down Expand Up @@ -2696,9 +2696,9 @@ def diagnostic_initialize_inputs(self):
if self.species is None:
species_names = pywarpx.particles.species_names
elif np.iterable(self.species):
species_names = [specie.name for specie in self.species]
species_names = [species.name for species in self.species]
else:
species_names = [species.name]
species_names = [self.species.name]

for name in species_names:
diag = pywarpx.Bucket.Bucket(self.name + '.' + name,
Expand Down

0 comments on commit 511fb37

Please sign in to comment.