Minerva命令行界面

minerva-cli的Python项目详细描述


密涅瓦CLI

简介

Minerva命令行界面允许上传和导入显微镜图像到Minerva Cloud。图像也可以从Minerva Cloud导出,并以OME-TIFF格式保存到本地磁盘。在

配置

默认情况下,Minerva将在用户的主目录中查找名为.Minerva的文件并从该文件加载配置。Minerva需要配置才能连接到正确的Minerva服务。在

命令行中给定的参数将覆盖配置文件中设置的值。[Config-location可被参数-Config覆盖]

{setup{miner命令可以通过cdva}运行 然后,Minerva CLI将提示您输入以下信息:

Parameter nameDescription
MINERVA_REGIONus-east-1 (aws region where Minerva is installed)
MINERVA_USERNAMEMinerva Username (can be left empty)
MINERVA_PASSWORDMinerva Password (can be left empty)
MINERVA_ENDPOINTAPI Gateway stage URL, e.g. https://xxxxxxxxxx.execute-api.us-east-1.amazonaws.com/dev
MINERVA_CLIENT_IDCognito App client id for the user pool

还提供了一个配置文件示例,以便于编辑该文件。收到。密涅瓦。例子设置为$HOME/.minerva,并使用文本编辑器打开文件以编辑值。所有参数值也可以用环境变量设置。在

显示帮助

python minerva.py

将图像目录导入Minerva Cloud

将REPOSITORY_NAME替换为REPOSITORY名称,将PATH_TO_DIRECTORY替换为目录路径。 将导入目录及其子目录中的所有图像。在

^{pr2}$

导入单个文件。在

python minerva.py import -r REPOSITORY_NAME -f PATH_TO_FILE```

导入OME TIFF时,参数--local将在本地处理图像,通常只使用一个或几个图像可以加快导入速度。在

python minerva.py import -r REPOSITORY_NAME -f PATH_TO_FILE --local```

将OME-TIFF从Minerva Cloud导出到本地磁盘

以下命令将按默认名称导出和保存图像,并且仅保存 最高金字塔级别。在

python minerva.py export --id IMAGE_UUID

靠氧气运转

安装

# Log in O2 with SSH# Clone the minerva-cli repository
git clone https://github.com/labsyspharm/minerva-cli.git

# Load necessary modules (you may need to restart bash shell after running this the first time)
module load conda2

# Create conda environment
conda create --name minerva python=3.6
conda activate minerva
pip install -r requirements.txt

# Configure minerva.config
cp .minerva.example ~/.minerva
# Edit the values in config file
nano minerva.config
# It's a good idea to prevent other users from reading your configuration file
chmod 700 ~/.minerva

将图像从ImStor导入Minerva Cloud

# Log in O2 transfer node with SSH (replace ecommonsid with your eCommons user id)
ssh ecommonsid@transfer.rc.hms.harvard.edu
# Copy images from ImStor to scratch space, e.g.
mkdir -p /n/scratch3/$USER/dataset
cp /n/files/ImStor/.../image.ome.tif /n/scratch3/$USER/dataset

# Log in O2 with SSH
ssh ecommons@o2.hms.harvard.edu
# Start interactive O2 session
srun --pty -p interactive --mem 500M -t 0-06:00 /bin/bash

# Activate conda environment
conda activate minerva

# Run Minerva import# (replace [REPOSITORY] with a repository name)# All the images from the given directory will be imported
python $HOME/minerva-cli/minerva.py import -r [REPOSITORY] -d /n/scratch3/$USER/dataset

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
如何使用SeleniumWebDriver捕获特定元素的屏幕截图而不是整个页面?   WAS 8.5中的java JAXWS异步IO异常   java Android Studio无法解析数组适配器中的符号项   swing Java在运行时添加和删除按钮   java Spring Boot 2.0。x禁用特定配置文件的安全性   java这是我的最后一个代码,我在“if(Users[B].substring(0,1)==“1”){//Find String Cut Char Function”上遇到错误   单击菜单选项后打开“活动”时发生java错误   java Tic Tac Toe NullPointerException   java如何做数学题。随机进入for循环   java Http状态404错误处理spring mvc   java循环依赖双向@OneToMany JPA关系   java我可以在不重新启动项目的情况下添加servlet吗   java在蓝色/绿色部署中如何管理共享数据库?   这是一个系统。currentTimeMillis()是Java中时间性能的最佳度量?