Skip to content

Commit 72493f2

Browse files
authored
Merge branch 'lhqing:master' into zarr_parallel
2 parents e178fc3 + c9f7be2 commit 72493f2

9 files changed

Lines changed: 17 additions & 15 deletions

File tree

.bumpversion.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[bumpversion]
2-
current_version = 1.1.0
2+
current_version = 1.1.1
33
tag = True
44
commit = True
55

.pre-commit-config.yaml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,24 +2,24 @@ fail_fast: false
22
default_language_version:
33
python: python3
44
default_stages:
5-
- commit
6-
- push
5+
- pre-commit
6+
- pre-push
77
minimum_pre_commit_version: 2.16.0
88
repos:
99
- repo: https://github.com/psf/black
10-
rev: 24.4.2
10+
rev: 25.1.0
1111
hooks:
1212
- id: black
1313
- repo: https://github.com/pre-commit/mirrors-prettier
1414
rev: v4.0.0-alpha.8
1515
hooks:
1616
- id: prettier
1717
- repo: https://github.com/asottile/blacken-docs
18-
rev: 1.18.0
18+
rev: 1.19.1
1919
hooks:
2020
- id: blacken-docs
2121
- repo: https://github.com/PyCQA/isort
22-
rev: 5.13.2
22+
rev: 6.0.0
2323
hooks:
2424
- id: isort
2525
- repo: https://github.com/asottile/yesqa
@@ -34,7 +34,7 @@ repos:
3434
- flake8-bugbear
3535
- flake8-blind-except
3636
- repo: https://github.com/pre-commit/pre-commit-hooks
37-
rev: v4.6.0
37+
rev: v5.0.0
3838
hooks:
3939
- id: detect-private-key
4040
- id: check-ast
@@ -53,7 +53,7 @@ repos:
5353
- --remove-unused-variable
5454
- --ignore-init-module-imports
5555
- repo: https://github.com/PyCQA/flake8
56-
rev: 7.1.0
56+
rev: 7.1.2
5757
hooks:
5858
- id: flake8
5959
additional_dependencies:
@@ -64,7 +64,7 @@ repos:
6464
- flake8-bugbear
6565
- flake8-blind-except
6666
- repo: https://github.com/asottile/pyupgrade
67-
rev: v3.16.0
67+
rev: v3.19.1
6868
hooks:
6969
- id: pyupgrade
7070
args: [--py3-plus, --py38-plus, --keep-runtime-typing]

ALLCools/__main__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -322,7 +322,7 @@ def merge_allc_register_subparser(subparser):
322322
"--output_path",
323323
type=str,
324324
required=True,
325-
help="Path to the output merged ALLC file.",
325+
help="Path to the output merged ALLC file (specify tsv.gz extension)",
326326
)
327327

328328
parser_req.add_argument("--chrom_size_path", type=str, required=True, help=chrom_size_path_doc)

ALLCools/_merge_allc.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ def __init__(self, path, region):
4040
self.f_region = TabixIterator()
4141

4242
def readline(self):
43-
return self.f_region.next()
43+
return self.f_region.__next__()
4444

4545
def close(self):
4646
self.f.close()

ALLCools/count_matrix/dataset.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ def _determine_datasets(regions, quantifiers, chrom_size_path):
9898
"do not have index in its fourth column, adding it automatically. "
9999
"If this is not desired, add a fourth column containing UNIQUE IDs to the BED file.",
100100
)
101-
region_bed_df[name] = (f"{name}_{i}" for i in range(region_bed_df.shape[0]))
101+
region_bed_df[name] = [f"{name}_{i}" for i in range(region_bed_df.shape[0])]
102102
# check if name is unique()
103103
if region_bed_df.iloc[:, 3].duplicated().sum() > 0:
104104
raise ValueError(f"Region IDs in {region_path} (fourth column) are not unique.")

ALLCools/mcds/mcds.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1026,7 +1026,7 @@ def get_score_adata(
10261026
if quant_type.lower().startswith("hypo"):
10271027
quant_type = "hypo-score"
10281028
elif quant_type.lower().startswith("hyper"):
1029-
quant_type = "hyper_score"
1029+
quant_type = "hyper-score"
10301030
else:
10311031
pass
10321032
if quant_type not in QUANT_TYPES:

ALLCools/mcds/utilities.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ def highly_variable_methylation_feature(
260260

261261
# Select n_top_feature
262262
if n_top_feature is not None:
263-
feature_subset = df.index.isin(df.sort_values("dispersion_norm", ascending=False).index[:5000])
263+
feature_subset = df.index.isin(df.sort_values("dispersion_norm", ascending=False).index[:n_top_feature])
264264
else:
265265
max_disp = np.inf if max_disp is None else max_disp
266266
dispersion_norm[np.isnan(dispersion_norm)] = 0 # similar to Seurat

ALLCools/utilities.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,8 @@ def parse_mc_pattern(pattern: str) -> set:
7676
except KeyError:
7777
raise KeyError(f"Base {base} is not in IUPAC table.")
7878
context_set = {"".join(i) for i in itertools.product(*all_pos_list)}
79+
if pattern == "CH":
80+
context_set.add("CH")
7981
return context_set
8082

8183

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ maintainers = [
1010
urls.Documentation = "https://lhqing.github.io/ALLCools/intro.html"
1111
urls.Source = "https://github.com/lhqing/ALLCools"
1212
urls.Home-page = "https://github.com/lhqing/ALLCools"
13-
version = "1.1.0"
13+
version = "1.1.1"
1414
requires-python = ">=3.7"
1515
license = { file = "LICENSE" }
1616
readme = "README.md"

0 commit comments

Comments
 (0)