def METHOD_NAME(self):
    res = (EquipmentType.query
           .add_columns(EquipmentType.rooms.any(~Room.is_deleted))
           .options(joinedload('features'))
           .order_by(EquipmentType.name)
           .all())
    used_ids = {eq.id for eq, used in res if used}
    schema = EquipmentTypeSchema(many=True, context={'used_ids': used_ids})
    return schema.dump(eq for eq, __ in res)