Skip to content

Commit 9dc8199

Browse files
committed
partial update
1 parent e26f64d commit 9dc8199

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

ibllib/tests/qc/test_alignment_qc.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -200,8 +200,8 @@ def _03_alignments_disagree(self):
200200
self.alignments['2020-06-26T16:40:14_Karolina_Socha'],
201201
'2020-06-12T00:39:15_nate': self.alignments['2020-06-12T00:39:15_nate']}
202202
trajectory = copy.deepcopy(self.trajectory)
203-
trajectory.update({'json': alignments})
204-
traj = one.alyx.rest('trajectories', 'update', id=self.prev_traj_id, data=trajectory)
203+
trajectory.update({'probe_insertion': self.probe_id, 'json': alignments})
204+
traj = one.alyx.rest('trajectories', 'partial_update', id=self.prev_traj_id, data=trajectory)
205205
align_qc = AlignmentQC(self.probe_id, one=one, brain_atlas=brain_atlas, channels=False)
206206
align_qc.load_data(prev_alignments=traj['json'], xyz_picks=np.array(self.xyz_picks) / 1e6,
207207
cluster_chns=self.cluster_chns, depths=SITES_COORDINATES[:, 1],
@@ -217,8 +217,8 @@ def _04_alignments_agree(self):
217217
self.alignments['2020-06-19T10:52:36_noam.roth'],
218218
'2020-06-12T00:39:15_nate': self.alignments['2020-06-12T00:39:15_nate']}
219219
trajectory = copy.deepcopy(self.trajectory)
220-
trajectory.update({'json': alignments})
221-
traj = one.alyx.rest('trajectories', 'update', id=self.prev_traj_id, data=trajectory)
220+
trajectory.update({'probe_insertion': self.probe_id, 'json': alignments})
221+
traj = one.alyx.rest('trajectories', 'partial_update', id=self.prev_traj_id, data=trajectory)
222222
self.assertEqual(self.prev_traj_id, traj['id'])
223223
align_qc = AlignmentQC(self.probe_id, one=one, brain_atlas=brain_atlas, channels=False)
224224
align_qc.load_data(cluster_chns=self.cluster_chns, depths=SITES_COORDINATES[:, 1],
@@ -231,8 +231,8 @@ def _04_alignments_agree(self):
231231
def _05_not_latest_alignments_agree(self):
232232
alignments = copy.deepcopy(self.alignments)
233233
trajectory = copy.deepcopy(self.trajectory)
234-
trajectory.update({'json': alignments})
235-
traj = one.alyx.rest('trajectories', 'update', id=self.prev_traj_id, data=trajectory)
234+
trajectory.update({'probe_insertion': self.probe_id, 'json': alignments})
235+
traj = one.alyx.rest('trajectories', 'partial_update', id=self.prev_traj_id, data=trajectory)
236236
self.assertEqual(self.prev_traj_id, traj['id'])
237237
align_qc = AlignmentQC(self.probe_id, one=one, brain_atlas=brain_atlas, channels=False)
238238
align_qc.load_data(prev_alignments=traj['json'], xyz_picks=np.array(self.xyz_picks) / 1e6,

0 commit comments

Comments
 (0)