From 63b39d8d49a762830b15324ada8620b885a79992 Mon Sep 17 00:00:00 2001 From: cjd24 Date: Thu, 26 Apr 2018 07:01:41 +0100 Subject: fixing czi live tiles and adding support for scn live tiles --- src/conversion/czi/czi.ts | 2 +- src/conversion/czi/pyramidWorker.ts | 42 +++++++---- src/conversion/czi/supatest.ts | 14 ++++ src/conversion/czi/tileExtraction.ts | 122 ------------------------------- src/conversion/leica/requestconvertor.ts | 56 +++++++++++++- src/conversion/leica/scn.ts | 17 +---- src/conversion/types/tileExtraction.ts | 122 +++++++++++++++++++++++++++++++ src/files.ts | 57 +++++++++++---- 8 files changed, 265 insertions(+), 167 deletions(-) create mode 100644 src/conversion/czi/supatest.ts delete mode 100644 src/conversion/czi/tileExtraction.ts create mode 100644 src/conversion/types/tileExtraction.ts diff --git a/src/conversion/czi/czi.ts b/src/conversion/czi/czi.ts index b611b8b..e56cae1 100644 --- a/src/conversion/czi/czi.ts +++ b/src/conversion/czi/czi.ts @@ -7,7 +7,7 @@ import { logger, Logger } from '../../logger'; import * as sharp from 'sharp'; // tslint:disable-next-line:no-duplicate-imports import { SharpInstance } from 'sharp'; -import { isTileRelated, regionToExtract } from './tileExtraction'; +import { isTileRelated, regionToExtract } from '../types/tileExtraction'; import * as parsexml from 'xml-parser'; import { uuid } from '../../uuid' import { queue as jobQueue, Promiser as Job } from '../../ppq' diff --git a/src/conversion/czi/pyramidWorker.ts b/src/conversion/czi/pyramidWorker.ts index 9851c1f..7adb747 100644 --- a/src/conversion/czi/pyramidWorker.ts +++ b/src/conversion/czi/pyramidWorker.ts @@ -2,7 +2,7 @@ import { WholeCZIHierarchy, CZIHeightMap, CZITile, CZITileRequest } from '../typ import { TileBounds, execpaths } from '../types/helpers'; import * as sharp from 'sharp'; import { SharpInstance } from 'sharp'; -import { isTileRelated } from './tileExtraction'; +import { isTileRelated } from '../types/tileExtraction'; import { uuid } from '../../uuid' import * as fs from 'fs'; import { RequestError } from '../../errors' @@ -11,7 +11,7 @@ import { exec } from '../types/exec' import { queue as jobQueue, Promiser as Job } from '../../ppq' const shell = require('shelljs'); const readFile = require('util').promisify(fs.readFile); -const log: Logger = logger.for({component: "CZI Live Server"}); +let log: Logger; const findRelatedTiles: Function = function(plane: CZIHeightMap, desired: TileBounds): CZITile[][] { @@ -38,16 +38,18 @@ const findRelatedTiles: Function = function(plane: CZIHeightMap, desired: TileBo relatedTiles.push(tileRow); } } + return relatedTiles; }; export const getTile: Function = async function(imageDir: string, cVal: string, x:number = 0, y:number = 0, w:number = 1024, h:number = 1024, zoom: number = 1): Promise { - let layout: WholeCZIHierarchy = JSON.parse(await jobQueue.enqueue(2, readFile, null, imageDir + "/layout.json", 'utf8')); + log = logger.for({component: "CZI Live Server", req: {imageDir: imageDir, cVal: cVal, x:x = 0, y:y = 0, w:w, h:h, zoom: zoom}}); + + let layout: WholeCZIHierarchy = JSON.parse(await jobQueue.enqueue(2, readFile, null, imageDir + "layout.json", 'utf8')); if (!layout.complete) { throw new RequestError(400, "conversion_incomplete") } - let bound: TileBounds = new TileBounds(Number(x), Number(x) + Number(w), Number(y), Number(y) + Number(h)); let map: CZIHeightMap; try { @@ -57,7 +59,7 @@ export const getTile: Function = async function(imageDir: string, cVal: string, } map = layout.c_values[Number(cVal)].height_map[reqZoom]; } catch (err) { - logger.error(err); + log.error(err); throw new RequestError(500, "missing_layout_item") } if (!map) { @@ -69,10 +71,12 @@ export const getTile: Function = async function(imageDir: string, cVal: string, const getFinalTile: Function = async function(imageDir: string, imageTier: CZIHeightMap, cVal: string, desiredRegion: TileBounds): Promise { - let involvedTiles: string = ''; - for (const row of imageTier.plane) { + let relatedTiles: CZITile[][] = findRelatedTiles(imageTier, desiredRegion); + + let involvedTiles:string = ''; + for (const row of relatedTiles) { for (const tile of row) { - involvedTiles += `${imageDir}/data/${tile.file} ` + involvedTiles += `${imageDir}data/${tile.file} ` } } @@ -90,29 +94,35 @@ const getFinalTile: Function = async function(imageDir: string, imageTier: CZIHe } } + let extractionRegion = new TileBounds( + desiredRegion.left - relatedTiles[0][0].x_offset, + desiredRegion.right - relatedTiles[0][0].x_offset, + desiredRegion.top - relatedTiles[0][0].y_offset, + desiredRegion.bottom - relatedTiles[0][0].y_offset + ); - desiredRegion.scaleDown(imageTier.zoom_level); + extractionRegion.scaleDown(imageTier.zoom_level); let final: SharpInstance = sharp(intermediateFileName) .extract({ - top: desiredRegion.top, - left: desiredRegion.left, - width: desiredRegion.width(), - height: desiredRegion.height() + top: extractionRegion.top, + left: extractionRegion.left, + width: extractionRegion.width(), + height: extractionRegion.height() }); await jobQueue.enqueue(2, final.toFile as Job, final, outputFileName); fs.unlink(intermediateFileName, (err:any) => { if (err) { - logger.warn("Couldn't delete: " + intermediateFileName); + log.warn("Couldn't delete: " + intermediateFileName); } }) log.info(`Gen new Tile: ${outputFileName} X:${desiredRegion.left} Y:${desiredRegion.top} W:${desiredRegion.width()} H:${desiredRegion.height()} Z:${cVal}`); return { dimensions: new TileBounds( - 0, desiredRegion.width(), - 0, desiredRegion.height() + 0, extractionRegion.width(), + 0, extractionRegion.height() ), original_bounds: desiredRegion, zoom_level: imageTier.zoom_level, diff --git a/src/conversion/czi/supatest.ts b/src/conversion/czi/supatest.ts new file mode 100644 index 0000000..934c0d2 --- /dev/null +++ b/src/conversion/czi/supatest.ts @@ -0,0 +1,14 @@ +// import * as sharp from 'sharp'; +// // tslint:disable-next-line:no-duplicate-imports +// import { SharpInstance } from 'sharp'; +// +// +// +// /** +// * Main function used to call the rest of the relevant code to crunch a CZI +// * extraction. +// */ +// const main: () => Promise = async (): Promise => { +// console.log(await sharp(`/cs/scratch/cjd24/0701-extraction-processed/tmp/img-0.png`).metadata()); +// }; +// main().then().catch(err => console.log(err)); diff --git a/src/conversion/czi/tileExtraction.ts b/src/conversion/czi/tileExtraction.ts deleted file mode 100644 index 83f63a5..0000000 --- a/src/conversion/czi/tileExtraction.ts +++ /dev/null @@ -1,122 +0,0 @@ -import { TileBounds } from '../types/helpers'; - -export const isTileRelated: Function = function(origCoords: TileBounds, desired: TileBounds): boolean { - - if (((desired.left >= origCoords.left) && - (desired.left < origCoords.right)) || - - // Desired X on right is within the current tile - ((desired.right > origCoords.left) && - (desired.right <= origCoords.right)) || - - // Desired tile X overlaps base tile - ((desired.left < origCoords.left) && - (desired.right > origCoords.right))) { - - // Desired Y on top is within current tile - if (((desired.top >= origCoords.top) && - (desired.top < origCoords.bottom)) || - - // Desired Y on right is within the current tile - ((desired.bottom > origCoords.top) && - (desired.bottom <= origCoords.bottom)) || - - // Desired tile Y overlaps whole base tile - ((desired.top < origCoords.top) && - (desired.bottom > origCoords.bottom))) { - - //If all of the if statements have passed, then this tile - //is part of the overlap for the new tile to be created. - return true; - } - } - return false; -}; - -/* - * Takes a base tile, and the whole bounds of a new tile, and uses this - * to calculate the region within the base tile that is overlapping the new tile - * to be extracted. - */ -export const regionToExtract: Function = function(baseBounds: TileBounds, desired: TileBounds, zoomLevel: number): TileBounds { - - //get the base tile area and create an object for the chunk to extract - const chunkToExtract: TileBounds = new TileBounds(-1, -1, -1, -1); - - // check if the new tile overlaps the leftmost boundary - if (desired.left <= baseBounds.left) { - chunkToExtract.left = 0; - } else { - chunkToExtract.left = desired.left - baseBounds.left; - } - - // check if the new tile overlaps the rightmost boundary - if (desired.right >= baseBounds.right) { - chunkToExtract.right = baseBounds.right - baseBounds.left; - } else { - chunkToExtract.right = desired.right - baseBounds.left; - } - - // check if the new tile overlaps the top boundary - if (desired.top <= baseBounds.top) { - chunkToExtract.top = 0; - } else { - chunkToExtract.top = desired.top - baseBounds.top; - } - - // check if the new tile overlaps the bottom boundary - if (desired.bottom >= baseBounds.bottom) { - chunkToExtract.bottom = baseBounds.bottom - baseBounds.top; - } else { - chunkToExtract.bottom = desired.bottom - baseBounds.top; - } - - if (chunkToExtract.left < 0 || chunkToExtract.right < 0 || chunkToExtract.top < 0 || chunkToExtract.bottom < 0) { - throw new Error('Chunk to extract from base tile has invalid bound (< 0).'); - } - - chunkToExtract.left = Math.ceil(chunkToExtract.left / zoomLevel); - chunkToExtract.right = Math.ceil(chunkToExtract.right / zoomLevel); - chunkToExtract.top = Math.ceil(chunkToExtract.top / zoomLevel); - chunkToExtract.bottom = Math.ceil(chunkToExtract.bottom / zoomLevel); - - //return the slice within the base tile for extraction - return chunkToExtract; -}; - -// export const createHorizontalImageSlice: Function = async function (bufferBound: TileBounds, tileSize: number, tileOverlap: number, rowLength:number, row: Buffer[]): Promise { -// //prepare variables to squash all of the column data into one, for this row -// let imageVerticalSlice: SharpInstance = sharp(row[0]); -// //check if the inital chunk needs to be extended to support the other columns -// if ((bufferBound.right - bufferBound.left) < (tileSize - tileOverlap)) { -// imageVerticalSlice = await imageVerticalSlice.background({r: 0, g: 0, b: 0, alpha: 0}).extend( -// {top:0, left:0, bottom:0, right: (tileSize - (bufferBound.right - bufferBound.left))}); -// } -// //for every column along this row, join it to the previous column data -// for (let index = 1; index < rowLength; index++) { -// imageVerticalSlice = await imageVerticalSlice -// .overlayWith(row[index], -// {top: 0, left: (bufferBound.right - bufferBound.left) + ((index -1) * tileSize)}); -// } -// return imageVerticalSlice.toBuffer(); -// } -// -// -// export const createImageFromHorizontalSlices: Function = async function(bufferBound: TileBounds, horizontalSlices: Buffer[], tileSize: number, tileOverlap: number, rowCount: number, tiles: CZITile[][]): Promise { -// //prepare variables used to combine all rows into one image -// let finalImage: SharpInstance = sharp(horizontalSlices[0]); -// -// //Check if the inital row needs to be extended to support further rows -// if ((bufferBound.bottom - bufferBound.top) < (tileSize - tileOverlap)) { -// finalImage = await finalImage.background({r: 0, g: 0, b: 0, alpha: 0}).extend( -// {top:0, left:0, bottom: (tileSize - (bufferBound.bottom - bufferBound.top)), right: 0}); -// } -// //For all further rows in the image, combine it with the previous rows' data -// for (let index = 1; index < rowCount; index++) { -// finalImage = finalImage.overlayWith( -// horizontalSlices[index], -// {top: tiles[index - 1][0].height, left: 0}); -// } -// -// return finalImage; -// } diff --git a/src/conversion/leica/requestconvertor.ts b/src/conversion/leica/requestconvertor.ts index 50002d7..f99ba6c 100644 --- a/src/conversion/leica/requestconvertor.ts +++ b/src/conversion/leica/requestconvertor.ts @@ -1 +1,55 @@ -import { logger } from '../../logger'; +import { CZITileRequest } from '../types/customPyramidIndex'; +import { TileBounds } from '../types/helpers'; +import * as sharp from 'sharp'; +import { SharpInstance } from 'sharp'; +import { uuid } from '../../uuid' +import { logger, Logger } from '../../logger' +import { queue as jobQueue, Promiser as Job } from '../../ppq' +import * as fs from 'fs'; +const readFile = require('util').promisify(fs.readFile); +let log: Logger; + +export const getTile: Function = async function(imageDir: string, cVal: string, x:number = 0, y:number = 0, w:number = 1024, h:number = 1024, zoom: number = 1): Promise { + log = logger.for({component: "SCN Live Server", req: {imageDir: imageDir, cVal: cVal, x:x = 0, y:y = 0, w:w, h:h, zoom: zoom}}); + + let orig: SharpInstance = await sharp(imageDir + "ORIGINAL"); + + let id: string = uuid.generate(); + let outputFileName: string = `${imageDir}tmp/${id}-out.png` + + let desiredRegion: TileBounds = new TileBounds(Number(x), Number(x) + Number(w), Number(y), Number(y) + Number(h)) + + orig + .extract({ + top: desiredRegion.top, + left: desiredRegion.left, + width: desiredRegion.width(), + height: desiredRegion.height() + }); + + let extractionRegion: TileBounds = desiredRegion; + extractionRegion.scaleDown(Math.log2(zoom) + 1); + + orig + .resize(extractionRegion.width(), extractionRegion.height()) + + await jobQueue.enqueue(2, orig.toFile as Job, orig, outputFileName); + + log.info(`Gen new Tile: ${outputFileName} X:${desiredRegion.left} Y:${desiredRegion.top} W:${desiredRegion.width()} H:${desiredRegion.height()} Z:*Ignored*`); + return { + dimensions: new TileBounds( + 0, extractionRegion.width(), + 0, extractionRegion.height() + ), + original_bounds: desiredRegion, + zoom_level: Math.log2(zoom), + c_value: "*Ignored*", + file_path: outputFileName + }; +} + +// +// const main: Function = async function(imageDir: string, cVal: string, x:number = 0, y:number = 0, w:number = 1024, h:number = 1024, zoom: number = 1): Promise { +// console.log(await getTile("/cs/scratch/cjd24/tifers/c206879a-5602-4d69-b2e9-b5b2adc43c7e/", 3, 0, 0, 1000, 2000, 512)); +// } +// main(); diff --git a/src/conversion/leica/scn.ts b/src/conversion/leica/scn.ts index a7d4573..f4de7c8 100644 --- a/src/conversion/leica/scn.ts +++ b/src/conversion/leica/scn.ts @@ -7,25 +7,15 @@ import { uuid } from '../../uuid' import { logger, Logger } from '../../logger'; let log: Logger; -// CHANGE ME FOR TESTING!!!!! -const input: string = "diseessse1.scn" -const baseDirname: string = '/cs/scratch/cjd24/tifers/'; - - - -// Various constants for placing files and defining tiles -const extensionBinariesDir: string = __dirname + `/../../../ext/bin/`; - const tileOverlap: number = 0; // Overlap is only half implemented const tileSize: number = 512; - export const crunchLeica: (original: string, space:string) => Promise = async (original: string, space:string): Promise => { log = logger.for({component: "SCN Crunch", targetFile: original}); try { let leica: SharpInstance = sharp(original).png(); - checkForOutputDirectories([space]); + checkForOutputDirectories([space, space + "tmp/"]); log.info("Creating new output directory for LECIA > DZI @ " + space); let meta: sharp.Metadata = await leica.metadata(); @@ -77,15 +67,14 @@ export const crunchLeica: (original: string, space:string) => Promise = as writeJSONToFile(`${space}/supported_views.json`, supportedViews) log.info("Wrote supported_views object in: " + space); - await sharp(baseDirname + input) - .png() + await leica .tile({ size: tileSize, overlap: tileOverlap, layout: "dz" }) .toFile(`${space}/output`); - log.success(`Finalised output of ${input} as .dzi`); + log.success(`Finalised output of ${original} as .dzi`); } catch (err) { log.failure(`Lecia conversion failed with error: ${err}`) diff --git a/src/conversion/types/tileExtraction.ts b/src/conversion/types/tileExtraction.ts new file mode 100644 index 0000000..83f63a5 --- /dev/null +++ b/src/conversion/types/tileExtraction.ts @@ -0,0 +1,122 @@ +import { TileBounds } from '../types/helpers'; + +export const isTileRelated: Function = function(origCoords: TileBounds, desired: TileBounds): boolean { + + if (((desired.left >= origCoords.left) && + (desired.left < origCoords.right)) || + + // Desired X on right is within the current tile + ((desired.right > origCoords.left) && + (desired.right <= origCoords.right)) || + + // Desired tile X overlaps base tile + ((desired.left < origCoords.left) && + (desired.right > origCoords.right))) { + + // Desired Y on top is within current tile + if (((desired.top >= origCoords.top) && + (desired.top < origCoords.bottom)) || + + // Desired Y on right is within the current tile + ((desired.bottom > origCoords.top) && + (desired.bottom <= origCoords.bottom)) || + + // Desired tile Y overlaps whole base tile + ((desired.top < origCoords.top) && + (desired.bottom > origCoords.bottom))) { + + //If all of the if statements have passed, then this tile + //is part of the overlap for the new tile to be created. + return true; + } + } + return false; +}; + +/* + * Takes a base tile, and the whole bounds of a new tile, and uses this + * to calculate the region within the base tile that is overlapping the new tile + * to be extracted. + */ +export const regionToExtract: Function = function(baseBounds: TileBounds, desired: TileBounds, zoomLevel: number): TileBounds { + + //get the base tile area and create an object for the chunk to extract + const chunkToExtract: TileBounds = new TileBounds(-1, -1, -1, -1); + + // check if the new tile overlaps the leftmost boundary + if (desired.left <= baseBounds.left) { + chunkToExtract.left = 0; + } else { + chunkToExtract.left = desired.left - baseBounds.left; + } + + // check if the new tile overlaps the rightmost boundary + if (desired.right >= baseBounds.right) { + chunkToExtract.right = baseBounds.right - baseBounds.left; + } else { + chunkToExtract.right = desired.right - baseBounds.left; + } + + // check if the new tile overlaps the top boundary + if (desired.top <= baseBounds.top) { + chunkToExtract.top = 0; + } else { + chunkToExtract.top = desired.top - baseBounds.top; + } + + // check if the new tile overlaps the bottom boundary + if (desired.bottom >= baseBounds.bottom) { + chunkToExtract.bottom = baseBounds.bottom - baseBounds.top; + } else { + chunkToExtract.bottom = desired.bottom - baseBounds.top; + } + + if (chunkToExtract.left < 0 || chunkToExtract.right < 0 || chunkToExtract.top < 0 || chunkToExtract.bottom < 0) { + throw new Error('Chunk to extract from base tile has invalid bound (< 0).'); + } + + chunkToExtract.left = Math.ceil(chunkToExtract.left / zoomLevel); + chunkToExtract.right = Math.ceil(chunkToExtract.right / zoomLevel); + chunkToExtract.top = Math.ceil(chunkToExtract.top / zoomLevel); + chunkToExtract.bottom = Math.ceil(chunkToExtract.bottom / zoomLevel); + + //return the slice within the base tile for extraction + return chunkToExtract; +}; + +// export const createHorizontalImageSlice: Function = async function (bufferBound: TileBounds, tileSize: number, tileOverlap: number, rowLength:number, row: Buffer[]): Promise { +// //prepare variables to squash all of the column data into one, for this row +// let imageVerticalSlice: SharpInstance = sharp(row[0]); +// //check if the inital chunk needs to be extended to support the other columns +// if ((bufferBound.right - bufferBound.left) < (tileSize - tileOverlap)) { +// imageVerticalSlice = await imageVerticalSlice.background({r: 0, g: 0, b: 0, alpha: 0}).extend( +// {top:0, left:0, bottom:0, right: (tileSize - (bufferBound.right - bufferBound.left))}); +// } +// //for every column along this row, join it to the previous column data +// for (let index = 1; index < rowLength; index++) { +// imageVerticalSlice = await imageVerticalSlice +// .overlayWith(row[index], +// {top: 0, left: (bufferBound.right - bufferBound.left) + ((index -1) * tileSize)}); +// } +// return imageVerticalSlice.toBuffer(); +// } +// +// +// export const createImageFromHorizontalSlices: Function = async function(bufferBound: TileBounds, horizontalSlices: Buffer[], tileSize: number, tileOverlap: number, rowCount: number, tiles: CZITile[][]): Promise { +// //prepare variables used to combine all rows into one image +// let finalImage: SharpInstance = sharp(horizontalSlices[0]); +// +// //Check if the inital row needs to be extended to support further rows +// if ((bufferBound.bottom - bufferBound.top) < (tileSize - tileOverlap)) { +// finalImage = await finalImage.background({r: 0, g: 0, b: 0, alpha: 0}).extend( +// {top:0, left:0, bottom: (tileSize - (bufferBound.bottom - bufferBound.top)), right: 0}); +// } +// //For all further rows in the image, combine it with the previous rows' data +// for (let index = 1; index < rowCount; index++) { +// finalImage = finalImage.overlayWith( +// horizontalSlices[index], +// {top: tiles[index - 1][0].height, left: 0}); +// } +// +// return finalImage; +// } diff --git a/src/files.ts b/src/files.ts index fdcc38d..426e5ac 100644 --- a/src/files.ts +++ b/src/files.ts @@ -9,7 +9,9 @@ import { default as File } from './db/model/File'; import { default as Project } from './db/model/Project'; import { uuid } from './uuid'; import { main as CZICrunch } from './conversion/czi/czi' -import { getTile } from './conversion/czi/pyramidWorker' +import { crunchLeica as SCNCrunch } from './conversion/leica/scn'; +import { getTile as getSCNTile } from './conversion/leica/requestconvertor'; +import { getTile as getCZITile } from './conversion/czi/pyramidWorker' import { RequestError } from './errors'; import { toCSV as excelToCSV, buildSupportedViews } from './conversion/csv/excel'; import { profiler } from './profiler'; @@ -402,15 +404,30 @@ export const views: { if (!cacheHit) { try { - let retMe: CZITileRequest = await getTile( - path(file.uuid, project.name, 'scalable_image') + '/', - query.channel_name, - query.x_offset, - query.y_offset, - query.width, - query.height, - query.zoom_level - ); + let retMe: CZITileRequest; + if (file.originalMimetype.includes('tif')) { + retMe = await getSCNTile( + path(file.uuid, project.name, 'scalable_image') + '/', + query.channel_name, + query.x_offset, + query.y_offset, + query.width, + query.height, + query.zoom_level + ); + } else if (file.originalMimetype.includes('czi')) { + retMe = await getCZITile( + path(file.uuid, project.name, 'scalable_image') + '/', + query.channel_name, + query.x_offset, + query.y_offset, + query.width, + query.height, + query.zoom_level + ); + } else { + throw new RequestError(400, "bad_tile_mimetype"); + } avgReqDuration.update(Date.now() - startTime) cache.set(url, retMe.file_path); cacheHit = retMe.file_path; @@ -435,8 +452,10 @@ export const views: { return; } var buffer = new Buffer(10); - fs.read(fd, buffer, 0, 10, 0, function(err, num) { + fs.read(fd, buffer, 0, 10, 0, async function(err, num) { logger.debug(buffer.toString('utf8', 0, num)); + file.originalMimetype = 'image/czi'; + await file.save(); res(buffer.toString('utf8', 0, num) === 'ZISRAWFILE'); }); }); @@ -444,11 +463,13 @@ export const views: { if (isCZI) { CZICrunch(original, space); + } else if (file.originalMimetype.includes('tif')){ + SCNCrunch(original, space); } else { const mt: string = file.originalMimetype; let validType: boolean = false; - logger.crit("FILES OTHER THAN CZI CURRENTLY NOT IMPLEMENTED") + logger.crit("OTHER FILES CURRENTLY NOT IMPLEMENTED") // if (mt.includes("tif")) { // await lecialol(original, space, mt); @@ -526,7 +547,17 @@ class MimeTypeMap extends Map { export const mimes: MimeTypeMap = new MimeTypeMap([ [ 'inode/directory', 'directory' ], - [ 'text/csv', 'tabular' ] + [ 'text/csv', 'tabular' ], + [ 'application/vnd.ms-excel', 'tabular'], + [ 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', 'tabular'], + [ 'application/vnd.oasis.opendocument.text', 'tabular'], + [ 'application/vnd.oasis.opendocument.spreadsheet', 'tabular'], + [ 'image/leica', 'scalable_image'], + [ 'image/zeiss', 'scalable_image'], + [ 'image/czi', 'scalable_image'], + [ 'image/tif', 'scalable_image'], + [ 'image/bigtiff', 'scalable_image'], + [ 'image/tiff', 'scalable_image'] ]); export const rootPathId: string = '0'; -- cgit v1.2.1