dspin 1.5.3__tar.gz → 1.5.4__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dspin
3
- Version: 1.5.3
3
+ Version: 1.5.4
4
4
  Summary: Regulatory network models from single-cell perturbation profiling
5
5
  Home-page: https://github.com/JialongJiang/DSPIN
6
6
  Author: Jialong Jiang
@@ -42,7 +42,7 @@ Dynamic: summary
42
42
 
43
43
  D-SPIN is a computational framework for constructing regulatory network models of genes or gene programs from single-cell RNA-seq profiling of perturbation conditions. D-SPIN integrates information from multiple perturbation conditions for network inference with improved efficienty and accuracy. The regulatory network can be defined on single genes or gene programs (groups of coexpressed genes). The package includes implementation of gene program discovery, network inference, and network analysis.
44
44
 
45
- If D-SPIN is useful for your research, consider citing "D-SPIN constructs gene regulatory network models from multiplexed scRNA-seq data revealing organizing principles of cellular perturbation response" ([bioRxiv](https://www.biorxiv.org/content/10.1101/2023.04.19.537364)).
45
+ If D-SPIN is useful for your research, consider citing "D-SPIN constructs regulatory network models from scRNA-seq that reveal organizing principles of perturbation response" ([Cell](https://doi.org/10.1016/j.cell.2026.04.028)).
46
46
 
47
47
  ## Contact
48
48
 
@@ -1,6 +1,6 @@
1
1
  # DSPIN
2
2
 
3
- Tutorial, code and examples of the D-SPIN framework for the preprint "D-SPIN constructs gene regulatory network models from multiplexed scRNA-seq data revealing organizing principles of cellular perturbation response" ([bioRxiv](https://www.biorxiv.org/content/10.1101/2023.04.19.537364))
3
+ Tutorial, code and examples of the D-SPIN framework for the paper "D-SPIN constructs regulatory network models from scRNA-seq that reveal organizing principles of perturbation response" ([Cell](https://doi.org/10.1016/j.cell.2026.04.028))
4
4
 
5
5
  <div align="center">
6
6
  <img src="figure/readme/Overview_20251110.png" width="800">
@@ -82,7 +82,7 @@ model.network_inference(
82
82
  directed=True,
83
83
  # optional priors / constraints:
84
84
  # sample_list_ordered=None,
85
- # perturb_matrix=None, # shape: (n_genes, n_samples)
85
+ # perturb_matrix_prior=None, # shape: (n_genes, n_samples)
86
86
  # prior_network=None, # binary matrix of likely edges (e.g., motif/ATAC prior)
87
87
  run_with_matlab=False,
88
88
  params={'stepsz': 0.05, 'lambda_l1_j': 0.01}
@@ -103,7 +103,7 @@ model.response_relative_to_control(
103
103
  - `num_spin=adata.shape[1]` - gene-level network
104
104
  - `directed=True` - only supported with `pseudo_likelihood`
105
105
  - `prior_network` (optional) - prior knowledge on network edges (e.g., TF–motif binding, ATAC-seq data)
106
- - `perturb_matrix` (optional) - prior on direct perturbation targets (e.g., Perturb-seq)
106
+ - `perturb_matrix_prior` (optional) - prior on direct perturbation targets (e.g., Perturb-seq)
107
107
  - `run_with_matlab=True` - write variables to `save_path` for MATLAB inference on large datasets
108
108
 
109
109
  ---
@@ -226,7 +226,7 @@ dp.plot_response_heatmap(
226
226
 
227
227
  ## References
228
228
 
229
- 1. Jiang, Jialong, et al. "D-SPIN constructs gene regulatory network models from multiplexed scRNA-seq data revealing organizing principles of cellular perturbation response." bioRxiv (2023).
229
+ 1. Jiang, Jialong, et al. "D-SPIN constructs regulatory network models from scRNA-seq that reveal organizing principles of perturbation response." Cell 189(13):4159-4184.e35 (2026).
230
230
 
231
231
  2. Jiang, Jialong, and Thomson, Matt. "A guide to D-SPIN: constructing regulatory network models from single-cell RNA-seq perturbation data." bioRxiv (2025).
232
232
 
@@ -265,7 +265,7 @@ class AbstractDSPIN(ABC):
265
265
  params: dict = None,
266
266
  sample_list_ordered: List[str] = None,
267
267
  prior_network: np.ndarray = None,
268
- perturb_matrix: np.ndarray = None,
268
+ perturb_matrix_prior: np.ndarray = None,
269
269
  if_control_key: str = 'if_control',
270
270
  batch_key: str = 'batch',
271
271
  run_with_matlab: bool = False) -> None:
@@ -286,7 +286,7 @@ class AbstractDSPIN(ABC):
286
286
  List of ordered sample identifiers. Default is None.
287
287
  prior_network : np.ndarray, optional
288
288
  Binary matrix of preferred network connectivity from prior knowledge. Default is None.
289
- perturb_matrix : np.ndarray, optional
289
+ perturb_matrix_prior : np.ndarray, optional
290
290
  Matrix of putative relative responses to control samples. Default is None.
291
291
  if_control_key : str, optional
292
292
  Column name in `adata.obs` indicating whether a sample is a control. Default is 'if_control'.
@@ -338,7 +338,7 @@ class AbstractDSPIN(ABC):
338
338
  train_dat['j_prior_mask'] = prior_network
339
339
  train_dat['lambda_l1_j_prior_mask'] = 0.01
340
340
 
341
- if perturb_matrix is not None:
341
+ if perturb_matrix_prior is not None:
342
342
  if if_control_key not in self.adata.obs.columns:
343
343
  raise ValueError(f"Column '{if_control_key}' not found in adata.obs.")
344
344
  if batch_key not in self.adata.obs.columns:
@@ -351,7 +351,7 @@ class AbstractDSPIN(ABC):
351
351
  if_control = np.array([sample_to_control[sample] for sample in sample_list])
352
352
  batch_index = np.array([sample_to_batch[sample] for sample in sample_list])
353
353
 
354
- train_dat['perturb_matrix'] = perturb_matrix
354
+ train_dat['perturb_matrix'] = perturb_matrix_prior
355
355
  train_dat['if_control'] = if_control
356
356
  train_dat['batch_index'] = batch_index
357
357
  train_dat['lambda_l2_h_rela_prior'] = 0.5
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dspin
3
- Version: 1.5.3
3
+ Version: 1.5.4
4
4
  Summary: Regulatory network models from single-cell perturbation profiling
5
5
  Home-page: https://github.com/JialongJiang/DSPIN
6
6
  Author: Jialong Jiang
@@ -42,7 +42,7 @@ Dynamic: summary
42
42
 
43
43
  D-SPIN is a computational framework for constructing regulatory network models of genes or gene programs from single-cell RNA-seq profiling of perturbation conditions. D-SPIN integrates information from multiple perturbation conditions for network inference with improved efficienty and accuracy. The regulatory network can be defined on single genes or gene programs (groups of coexpressed genes). The package includes implementation of gene program discovery, network inference, and network analysis.
44
44
 
45
- If D-SPIN is useful for your research, consider citing "D-SPIN constructs gene regulatory network models from multiplexed scRNA-seq data revealing organizing principles of cellular perturbation response" ([bioRxiv](https://www.biorxiv.org/content/10.1101/2023.04.19.537364)).
45
+ If D-SPIN is useful for your research, consider citing "D-SPIN constructs regulatory network models from scRNA-seq that reveal organizing principles of perturbation response" ([Cell](https://doi.org/10.1016/j.cell.2026.04.028)).
46
46
 
47
47
  ## Contact
48
48
 
@@ -21,7 +21,7 @@ install_requires = [
21
21
  # ]
22
22
 
23
23
  # Managing your version (adjust accordingly)
24
- version = "1.5.3" # You can manage versioning in a more sophisticated way if needed
24
+ version = "1.5.4" # You can manage versioning in a more sophisticated way if needed
25
25
 
26
26
  # Long description (usually a README file)
27
27
  readme = open("README_PyPI.md").read() # Adjust the file name if necessary
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes