Skip to content

Commit d35c7c4

Browse files
committed
Added centrals and satellites properties to catalogue. Closes #74.
1 parent e370182 commit d35c7c4

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

velociraptor/catalogue/catalogue.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -412,3 +412,17 @@ def register_derived_quantities(self, registration_file_path: str) -> None:
412412
self.derived_quantities = DerivedQuantities(registration_file_path, self)
413413

414414
return
415+
416+
@property
417+
def centrals(self):
418+
if hasattr(self.structure_type, "structuretype"):
419+
return self.structure_type.structuretype == 10
420+
else:
421+
return np.s_[:]
422+
423+
@property
424+
def satellites(self):
425+
if hasattr(self.structure_type, "structuretype"):
426+
return self.structure_type.structuretype != 10
427+
else:
428+
return np.s_[:]

0 commit comments

Comments
 (0)