Skip to content

Commit

Permalink
Fixed aliased parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
lranzani committed Nov 20, 2024
1 parent cd8ac83 commit 307e7ed
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/auspex/qubit/pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
from functools import reduce
from IPython.display import HTML, display
from sqlalchemy import inspect
from sqlalchemy.orm import aliased

import auspex.config as config
import auspex.instruments
Expand Down Expand Up @@ -79,7 +80,11 @@ def __init__(self, force_new=False):
def add_qubit_pipeline(self, qubit_label, stream_type, auto_create=True, buffers=False):
# if qubit_label not in self.stream_selectors:
m = bbndb.qgl.Measurement
mqs = [l[0] for l in self.session.query(m.label).join(m.channel_db, aliased=True).filter_by(label="working").all()]
#n1 = aliased(m.label)

#mqs = [l[0] for l in self.session.query(m.label).join(m.channel_db.of_type(n1)).filter_by(n1.name == "working").all()]
mqs = [l[0] for l in self.session.query(m.label).join(m.channel_db).filter_by(label="working").all()]
#mqs = [l[0] for l in self.session.query(m.label).join(m.channel_db, aliased=True).filter_by(label="working").all()]
if f'M-{qubit_label}' not in mqs:
raise Exception(f"Could not find qubit {qubit_label} in pipeline...")

Expand Down

0 comments on commit 307e7ed

Please sign in to comment.