@vitessce/csv 3.4.8 → 3.4.10
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.
- package/dist/index.js +73 -10
- package/package.json +5 -5
package/dist/index.js
CHANGED
|
@@ -286,6 +286,7 @@ const FileType$1 = {
|
|
|
286
286
|
// Joint file types
|
|
287
287
|
ANNDATA_ZARR: "anndata.zarr",
|
|
288
288
|
ANNDATA_ZARR_ZIP: "anndata.zarr.zip",
|
|
289
|
+
ANNDATA_H5AD: "anndata.h5ad",
|
|
289
290
|
SPATIALDATA_ZARR: "spatialdata.zarr",
|
|
290
291
|
// Atomic file types
|
|
291
292
|
OBS_EMBEDDING_CSV: "obsEmbedding.csv",
|
|
@@ -326,6 +327,18 @@ const FileType$1 = {
|
|
|
326
327
|
OBS_LABELS_ANNDATA_ZARR_ZIP: "obsLabels.anndata.zarr.zip",
|
|
327
328
|
FEATURE_LABELS_ANNDATA_ZARR_ZIP: "featureLabels.anndata.zarr.zip",
|
|
328
329
|
SAMPLE_EDGES_ANNDATA_ZARR_ZIP: "sampleEdges.anndata.zarr.zip",
|
|
330
|
+
// AnnData - h5ad via reference spec
|
|
331
|
+
OBS_FEATURE_MATRIX_ANNDATA_H5AD: "obsFeatureMatrix.anndata.h5ad",
|
|
332
|
+
OBS_FEATURE_COLUMNS_ANNDATA_H5AD: "obsFeatureColumns.anndata.h5ad",
|
|
333
|
+
OBS_SETS_ANNDATA_H5AD: "obsSets.anndata.h5ad",
|
|
334
|
+
OBS_EMBEDDING_ANNDATA_H5AD: "obsEmbedding.anndata.h5ad",
|
|
335
|
+
OBS_SPOTS_ANNDATA_H5AD: "obsSpots.anndata.h5ad",
|
|
336
|
+
OBS_POINTS_ANNDATA_H5AD: "obsPoints.anndata.h5ad",
|
|
337
|
+
OBS_LOCATIONS_ANNDATA_H5AD: "obsLocations.anndata.h5ad",
|
|
338
|
+
OBS_SEGMENTATIONS_ANNDATA_H5AD: "obsSegmentations.anndata.h5ad",
|
|
339
|
+
OBS_LABELS_ANNDATA_H5AD: "obsLabels.anndata.h5ad",
|
|
340
|
+
FEATURE_LABELS_ANNDATA_H5AD: "featureLabels.anndata.h5ad",
|
|
341
|
+
SAMPLE_EDGES_ANNDATA_H5AD: "sampleEdges.anndata.h5ad",
|
|
329
342
|
// SpatialData
|
|
330
343
|
IMAGE_SPATIALDATA_ZARR: "image.spatialdata.zarr",
|
|
331
344
|
LABELS_SPATIALDATA_ZARR: "labels.spatialdata.zarr",
|
|
@@ -6910,6 +6923,9 @@ const configSchema1_0_16 = configSchema1_0_13.extend({
|
|
|
6910
6923
|
coordinationScopesBy: componentCoordinationScopesBy.optional()
|
|
6911
6924
|
}))
|
|
6912
6925
|
});
|
|
6926
|
+
const configSchema1_0_17 = configSchema1_0_16.extend({
|
|
6927
|
+
version: z.literal("1.0.17")
|
|
6928
|
+
});
|
|
6913
6929
|
configSchema1_0_0.shape.coordinationSpace.unwrap();
|
|
6914
6930
|
configSchema1_0_0.shape.layout.element.shape.coordinationScopes.unwrap();
|
|
6915
6931
|
function upgradeReplaceViewProp(prefix, view, coordinationSpace) {
|
|
@@ -7381,7 +7397,43 @@ function upgradeFrom1_0_15(config) {
|
|
|
7381
7397
|
version: "1.0.16"
|
|
7382
7398
|
};
|
|
7383
7399
|
}
|
|
7384
|
-
|
|
7400
|
+
function upgradeFrom1_0_16(config) {
|
|
7401
|
+
const newConfig = cloneDeep(config);
|
|
7402
|
+
const { datasets } = newConfig;
|
|
7403
|
+
const newDatasets = datasets.map((datasetDef) => {
|
|
7404
|
+
const { files } = datasetDef;
|
|
7405
|
+
const newFiles = files.map((fileDef) => {
|
|
7406
|
+
const { fileType, options } = fileDef;
|
|
7407
|
+
if (fileType === "obsSets.anndata.zarr") {
|
|
7408
|
+
return {
|
|
7409
|
+
...fileDef,
|
|
7410
|
+
options: {
|
|
7411
|
+
obsSets: options
|
|
7412
|
+
}
|
|
7413
|
+
};
|
|
7414
|
+
}
|
|
7415
|
+
if (fileType === "obsFeatureColumns.anndata.zarr") {
|
|
7416
|
+
return {
|
|
7417
|
+
...fileDef,
|
|
7418
|
+
options: {
|
|
7419
|
+
obsFeatureColumns: options
|
|
7420
|
+
}
|
|
7421
|
+
};
|
|
7422
|
+
}
|
|
7423
|
+
return fileDef;
|
|
7424
|
+
});
|
|
7425
|
+
return {
|
|
7426
|
+
...datasetDef,
|
|
7427
|
+
files: newFiles
|
|
7428
|
+
};
|
|
7429
|
+
});
|
|
7430
|
+
return {
|
|
7431
|
+
...newConfig,
|
|
7432
|
+
datasets: newDatasets,
|
|
7433
|
+
version: "1.0.17"
|
|
7434
|
+
};
|
|
7435
|
+
}
|
|
7436
|
+
const latestConfigSchema = configSchema1_0_17;
|
|
7385
7437
|
const SCHEMA_HANDLERS = [
|
|
7386
7438
|
[configSchema0_1_0, upgradeFrom0_1_0],
|
|
7387
7439
|
[configSchema1_0_0, upgradeFrom1_0_0],
|
|
@@ -7399,7 +7451,8 @@ const SCHEMA_HANDLERS = [
|
|
|
7399
7451
|
[configSchema1_0_12, upgradeFrom1_0_12],
|
|
7400
7452
|
[configSchema1_0_13, upgradeFrom1_0_13],
|
|
7401
7453
|
[configSchema1_0_14, upgradeFrom1_0_14],
|
|
7402
|
-
[configSchema1_0_15, upgradeFrom1_0_15]
|
|
7454
|
+
[configSchema1_0_15, upgradeFrom1_0_15],
|
|
7455
|
+
[configSchema1_0_16, upgradeFrom1_0_16]
|
|
7403
7456
|
];
|
|
7404
7457
|
var re$3 = { exports: {} };
|
|
7405
7458
|
const SEMVER_SPEC_VERSION = "2.0.0";
|
|
@@ -9670,10 +9723,11 @@ function makeConstantWithDeprecationMessage(currObj, oldObj) {
|
|
|
9670
9723
|
const handler = {
|
|
9671
9724
|
get(obj, prop) {
|
|
9672
9725
|
const oldKeys = Object.keys(oldObj);
|
|
9673
|
-
|
|
9674
|
-
|
|
9675
|
-
${oldObj[
|
|
9676
|
-
|
|
9726
|
+
const propKey = String(prop);
|
|
9727
|
+
if (oldKeys.includes(propKey)) {
|
|
9728
|
+
console.warn(`Notice about the constant mapping ${propKey}: '${oldObj[propKey][0]}':
|
|
9729
|
+
${oldObj[propKey][1]}`);
|
|
9730
|
+
return oldObj[propKey];
|
|
9677
9731
|
}
|
|
9678
9732
|
return obj[prop];
|
|
9679
9733
|
}
|
|
@@ -9758,7 +9812,7 @@ const annDataObsFeatureMatrix = z.object({
|
|
|
9758
9812
|
featureFilterPath: z.string().optional().describe("If the feature index should be filtered, put a boolean column here (analogous to the previous geneFilter option). e.g., var/in_obsm_X_small_matrix"),
|
|
9759
9813
|
initialFeatureFilterPath: z.string().optional().describe("If only a subset of the matrix should be loaded initially, put a boolean column along the feature axis here (analogous to the previous matrixGeneFilter option). e.g., var/highly_variable")
|
|
9760
9814
|
});
|
|
9761
|
-
const
|
|
9815
|
+
const annDataObsSetsArr = z.array(z.object({
|
|
9762
9816
|
name: z.string().describe("The display name for the set, like 'Cell Type' or 'Louvain.'"),
|
|
9763
9817
|
path: z.union([
|
|
9764
9818
|
z.string().describe("The location in the AnnData store for the set, like 'obs/louvain' or 'obs/celltype.'"),
|
|
@@ -9766,9 +9820,15 @@ const annDataObsSets = z.array(z.object({
|
|
|
9766
9820
|
]),
|
|
9767
9821
|
scorePath: z.string().optional().describe("The location in the AnnData store for the set confidence scores, like 'obs/celltype_prediction_score.'")
|
|
9768
9822
|
}));
|
|
9769
|
-
z.
|
|
9823
|
+
const annDataObsSets = z.object({
|
|
9824
|
+
obsSets: annDataObsSetsArr
|
|
9825
|
+
});
|
|
9826
|
+
const annDataObsFeatureColumnsArr = z.array(z.object({
|
|
9770
9827
|
path: z.string()
|
|
9771
9828
|
}));
|
|
9829
|
+
z.object({
|
|
9830
|
+
obsFeatureColumns: annDataObsFeatureColumnsArr
|
|
9831
|
+
});
|
|
9772
9832
|
const annDataObsSpots = annDataObsm;
|
|
9773
9833
|
const annDataObsPoints = annDataObsm;
|
|
9774
9834
|
const annDataObsLocations = annDataObsm;
|
|
@@ -9891,7 +9951,7 @@ z.object({
|
|
|
9891
9951
|
scoreColumn: z.string().optional()
|
|
9892
9952
|
}))
|
|
9893
9953
|
});
|
|
9894
|
-
z.object({
|
|
9954
|
+
const anndataZarrSchema = z.object({
|
|
9895
9955
|
obsLabels: z.union([
|
|
9896
9956
|
annDataObsLabels,
|
|
9897
9957
|
z.array(annDataConvenienceObsLabelsItem)
|
|
@@ -9901,7 +9961,7 @@ z.object({
|
|
|
9901
9961
|
z.array(annDataConvenienceFeatureLabelsItem)
|
|
9902
9962
|
]),
|
|
9903
9963
|
obsFeatureMatrix: annDataObsFeatureMatrix,
|
|
9904
|
-
obsSets:
|
|
9964
|
+
obsSets: annDataObsSetsArr,
|
|
9905
9965
|
obsSpots: annDataObsSpots,
|
|
9906
9966
|
obsPoints: annDataObsPoints,
|
|
9907
9967
|
obsLocations: annDataObsLocations,
|
|
@@ -9912,6 +9972,9 @@ z.object({
|
|
|
9912
9972
|
]),
|
|
9913
9973
|
sampleEdges: annDataSampleEdges
|
|
9914
9974
|
}).partial();
|
|
9975
|
+
anndataZarrSchema.extend({
|
|
9976
|
+
refSpecUrl: z.string()
|
|
9977
|
+
});
|
|
9915
9978
|
z.object({
|
|
9916
9979
|
// TODO: should `image` be a special schema
|
|
9917
9980
|
// to allow specifying fileUid (like for embeddingType)?
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vitessce/csv",
|
|
3
|
-
"version": "3.4.
|
|
3
|
+
"version": "3.4.10",
|
|
4
4
|
"author": "Gehlenborg Lab",
|
|
5
5
|
"homepage": "http://vitessce.io",
|
|
6
6
|
"repository": {
|
|
@@ -18,10 +18,10 @@
|
|
|
18
18
|
"dependencies": {
|
|
19
19
|
"d3-array": "^2.4.0",
|
|
20
20
|
"d3-dsv": "^1.1.1",
|
|
21
|
-
"@vitessce/constants-internal": "3.4.
|
|
22
|
-
"@vitessce/sets-utils": "3.4.
|
|
23
|
-
"@vitessce/vit-s": "3.4.
|
|
24
|
-
"@vitessce/config": "3.4.
|
|
21
|
+
"@vitessce/constants-internal": "3.4.10",
|
|
22
|
+
"@vitessce/sets-utils": "3.4.10",
|
|
23
|
+
"@vitessce/vit-s": "3.4.10",
|
|
24
|
+
"@vitessce/config": "3.4.10"
|
|
25
25
|
},
|
|
26
26
|
"scripts": {
|
|
27
27
|
"bundle": "pnpm exec vite build -c ../../../scripts/vite.config.js",
|