Last active
June 12, 2020 23:59
-
-
Save oeway/523538d380058cad7c3ece9595fcc913 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<docs lang="markdown"> | |
[TODO: write documentation for this plugin.] | |
</docs> | |
<config lang="json"> | |
{ | |
"name": "Viv-demo", | |
"type": "native-python", | |
"version": "0.1.0", | |
"description": "[TODO: describe this plugin with one sentence.]", | |
"tags": [], | |
"ui": "", | |
"cover": "", | |
"inputs": null, | |
"outputs": null, | |
"flags": [], | |
"icon": "extension", | |
"api_version": "0.1.8", | |
"env": "", | |
"permissions": [], | |
"requirements": [], | |
"dependencies": [] | |
} | |
</config> | |
<script lang="python"> | |
from imjoy import api | |
covidTiffInfo = { | |
"url": | |
'https://vitessce-demo-data.storage.googleapis.com/test-data/12448_G1HR_Mesh003.ome.tif', | |
"dimensions": [ | |
{ | |
"field": 'channel', | |
"type": 'nominal', | |
"values": [0] | |
}, | |
{ "field": 'y', "type": 'quantitative', "values": None }, | |
{ "field": 'x', "type": 'quantitative', "values": None } | |
], | |
"selections": [{ "channel": 0 }], | |
"isPublic": True, | |
"isPyramid": True, | |
"description": 'Covid-19 Primary Gut Epithelial Stem Cells (OME-TIFF)', | |
"initialViewState": { | |
"zoom": -7, | |
"target": [50000, 50000] | |
} | |
}; | |
class ImJoyPlugin(): | |
async def setup(self): | |
pass | |
async def run(self, ctx): | |
viewer = await api.showDialog(src="https://oeway.github.io/vitessce-image-viewer/") | |
viewer.loadSource('covid tiff', covidTiffInfo) | |
api.export(ImJoyPlugin()) | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment