Skip to content

Commit

Permalink
fix: upgraded tiledb and reverted workaround (#61) (#66)
Browse files Browse the repository at this point in the history
  • Loading branch information
metakuni authored Sep 17, 2021
1 parent 055a64d commit 6841c72
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 22 deletions.
17 changes: 2 additions & 15 deletions server/compute/diffexp_cxg.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,24 +87,11 @@ def diffexp_ttest(adaptor, maskA, maskB, top_n=8, diffexp_lfc_cutoff=0.01):

if is_sparse:
for cols in col_partitions:
futures.append(
executor.submit(
# TODO: remove this temporary workaround when TileDB fixes the issue with multi_index
_mean_var_sparse_ab, adaptor.open_array("X"), row_selector_A, nA, row_selector_B, nB, cols
)
)
futures.append(executor.submit(_mean_var_sparse_ab, matrix, row_selector_A, nA, row_selector_B, nB, cols))
else:
for cols in col_partitions:
futures.append(
executor.submit(
_mean_var_ab,
# TODO: remove this temporary workaround when TileDB fixes the issue with multi_index
adaptor.open_array("X"),
row_selector_AB,
row_selector_A_in_AB,
row_selector_B_in_AB,
cols,
)
executor.submit(_mean_var_ab, matrix, row_selector_AB, row_selector_A_in_AB, row_selector_B_in_AB, cols)
)

for future in futures:
Expand Down
7 changes: 1 addition & 6 deletions server/data_cxg/cxg_adaptor.py
Original file line number Diff line number Diff line change
Expand Up @@ -195,12 +195,7 @@ def _open_array(uri, tiledb_ctx):
def open_array(self, name):
try:
p = self.get_path(name)
# TODO: remove this temporary workaround when TileDB fixes the issue with multi_index
if name == "X" or name == "X_col_shift":
# workaround: bypass the cache for arrays that use multi_index
return CxgAdaptor._open_array(p, self.tiledb_ctx)
else:
return self.arrays[p]
return self.arrays[p]
except tiledb.libtiledb.TileDBError:
raise DatasetAccessError(name)

Expand Down
2 changes: 1 addition & 1 deletion server/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@ pandas>=1.0,!=1.1 # pandas 1.1 breaks tests, https://github.com/pandas-dev/pand
PyYAML>=5.4 # CVE-2020-14343
scipy>=1.4
requests>=2.22.0
tiledb==0.10.0
tiledb==0.10.1
s3fs==0.4.2
sqlalchemy>=1.3.18

0 comments on commit 6841c72

Please sign in to comment.