Skip to content

Commit

Permalink
Fix #138
Browse files Browse the repository at this point in the history
  • Loading branch information
Bryan Bartley committed Apr 27, 2022
1 parent 802b65d commit 4abcfc9
Show file tree
Hide file tree
Showing 4 changed files with 42 additions and 57 deletions.
2 changes: 1 addition & 1 deletion paml/data.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ def is_in_mask(entry, row_col_pairs):
is_in_mask(coordinate_to_row_col(x), row_col_pairs)
for x in contents_array.data
],
coords={Strings.ALIQUOT: contents_array}
coords=[(Strings.ALIQUOT, contents_array.data)]
)
return json.dumps(mask_array.to_dict())
SampleArray.mask = sample_array_mask
Expand Down
4 changes: 2 additions & 2 deletions paml/sample_maps.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ def many_to_one_sample_map_get_map(self):
source_to_target_arrays = {
source.identity : xr.DataArray([""]*len(aliquots),
dims=(target.identity),
coords={target.identity: aliquots})
coords=[(target.identity, aliquots)])
for source in sources
}

Expand All @@ -68,7 +68,7 @@ def one_to_many_sample_map_get_map(self):
source_to_target_arrays = {
target.identity : xr.DataArray([""]*len(aliquots),
dims=(source.identity),
coords={source.identity: aliquots})
coords=[(source.identity, aliquots)])
for target in targets
}

Expand Down
4 changes: 2 additions & 2 deletions test/test_samplemap.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,8 @@ def test_create_protocol(self):
for reagent in reagents]
for id in aliquot_ids],
dims=("aliquot", "contents"),
coords={"aliquot": aliquot_ids,
"contents": [r.identity for r in reagents]}).to_dict()))
coords=[("aliquot", aliquot_ids),
("contents", [r.identity for r in reagents])]).to_dict()))
# 3.
sample_array_parameter = create_source.pin_parameter("sample_array")
[old_input] = [x for x in create_source.inputs if x.name == "sample_array"]
Expand Down
Loading

0 comments on commit 4abcfc9

Please sign in to comment.