Spaces:
Runtime error
Runtime error
lambda scientist
commited on
Commit
·
a2e6ff7
1
Parent(s):
ed97bb4
hug
Browse files- README.md +4 -2
- google_colab_deploy.ipynb +66 -0
- requirements.txt +4 -1
- start.sh +11 -0
README.md
CHANGED
@@ -4,12 +4,14 @@ emoji: 🔬
|
|
4 |
colorFrom: yellow
|
5 |
colorTo: purple
|
6 |
sdk: streamlit
|
7 |
-
sdk_version: 1.
|
8 |
app_file: Home.py
|
9 |
-
pinned: true
|
10 |
license: agpl-3.0
|
|
|
11 |
---
|
12 |
|
|
|
|
|
13 |
# MyoQuant-Streamlit🔬: a demo web interface for the MyoQuant tool.
|
14 |
|
15 |
## Please refer to the [MyoQuant GitHub Repository](https://github.com/lambda-science/MyoQuant) or the [MyoQuant PyPi repository](https://pypi.org/project/myoquant/) for full documentation.
|
|
|
4 |
colorFrom: yellow
|
5 |
colorTo: purple
|
6 |
sdk: streamlit
|
7 |
+
sdk_version: 1.19.0
|
8 |
app_file: Home.py
|
|
|
9 |
license: agpl-3.0
|
10 |
+
python: 3.10.9
|
11 |
---
|
12 |
|
13 |
+
![Twitter Follow](https://img.shields.io/twitter/follow/corentinm_py?style=social) ![Demo Version](https://img.shields.io/badge/Demo-https%3A%2F%2Flbgi.fr%2FMyoQuant%2F-9cf) ![PyPi](https://img.shields.io/badge/PyPi-https%3A%2F%2Fpypi.org%2Fproject%2Fmyoquant%2F-blueviolet) ![Pypi verison](https://img.shields.io/pypi/v/myoquant)
|
14 |
+
|
15 |
# MyoQuant-Streamlit🔬: a demo web interface for the MyoQuant tool.
|
16 |
|
17 |
## Please refer to the [MyoQuant GitHub Repository](https://github.com/lambda-science/MyoQuant) or the [MyoQuant PyPi repository](https://pypi.org/project/myoquant/) for full documentation.
|
google_colab_deploy.ipynb
ADDED
@@ -0,0 +1,66 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"cells": [
|
3 |
+
{
|
4 |
+
"cell_type": "code",
|
5 |
+
"execution_count": null,
|
6 |
+
"metadata": {},
|
7 |
+
"outputs": [],
|
8 |
+
"source": [
|
9 |
+
"!pip install -q streamlit\n",
|
10 |
+
"!pip install -q pyngrok\n",
|
11 |
+
"!pip install -q cellpose\n",
|
12 |
+
"!pip install -q stardist\n",
|
13 |
+
"!pip install -q imageio"
|
14 |
+
]
|
15 |
+
},
|
16 |
+
{
|
17 |
+
"cell_type": "code",
|
18 |
+
"execution_count": null,
|
19 |
+
"metadata": {},
|
20 |
+
"outputs": [],
|
21 |
+
"source": [
|
22 |
+
"from pyngrok import ngrok \n",
|
23 |
+
"public_url = ngrok.connect(port='8501')\n",
|
24 |
+
"# public_url"
|
25 |
+
]
|
26 |
+
},
|
27 |
+
{
|
28 |
+
"cell_type": "code",
|
29 |
+
"execution_count": null,
|
30 |
+
"metadata": {},
|
31 |
+
"outputs": [],
|
32 |
+
"source": [
|
33 |
+
"!git clone https://github.com/lambda-science/MyoQuant.git app\n",
|
34 |
+
"!wget https://lbgi.fr/~meyer/SDH_models/model.h5"
|
35 |
+
]
|
36 |
+
},
|
37 |
+
{
|
38 |
+
"cell_type": "code",
|
39 |
+
"execution_count": null,
|
40 |
+
"metadata": {},
|
41 |
+
"outputs": [],
|
42 |
+
"source": [
|
43 |
+
"!streamlit run /content/app/Home.py & npx localtunnel --port 8501"
|
44 |
+
]
|
45 |
+
}
|
46 |
+
],
|
47 |
+
"metadata": {
|
48 |
+
"kernelspec": {
|
49 |
+
"display_name": "Python 3.8.10 64-bit",
|
50 |
+
"language": "python",
|
51 |
+
"name": "python3"
|
52 |
+
},
|
53 |
+
"language_info": {
|
54 |
+
"name": "python",
|
55 |
+
"version": "3.8.10"
|
56 |
+
},
|
57 |
+
"orig_nbformat": 4,
|
58 |
+
"vscode": {
|
59 |
+
"interpreter": {
|
60 |
+
"hash": "31f2aee4e71d21fbe5cf8b01ff0e069b9275f58929596ceb00d14d90e3e16cd6"
|
61 |
+
}
|
62 |
+
}
|
63 |
+
},
|
64 |
+
"nbformat": 4,
|
65 |
+
"nbformat_minor": 2
|
66 |
+
}
|
requirements.txt
CHANGED
@@ -1,4 +1,7 @@
|
|
1 |
myoquant
|
|
|
|
|
2 |
imageio
|
3 |
pandas
|
4 |
-
matplotlib
|
|
|
|
1 |
myoquant
|
2 |
+
streamlit
|
3 |
+
pyngrok
|
4 |
imageio
|
5 |
pandas
|
6 |
+
matplotlib
|
7 |
+
ipykernel
|
start.sh
ADDED
@@ -0,0 +1,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
#!/bin/bash
|
2 |
+
source .venv/bin/activate
|
3 |
+
DIR=$(readlink -f $0 | xargs dirname)
|
4 |
+
PIDPATH=$DIR/.pid
|
5 |
+
|
6 |
+
if [ -f $PIDPATH ]; then
|
7 |
+
kill $(cat $PIDPATH)
|
8 |
+
fi
|
9 |
+
|
10 |
+
nohup streamlit run Home.py --server.baseUrlPath /MyoQuant --browser.serverAddress lbgi.fr --server.fileWatcherType none --browser.gatherUsageStats false --server.port 8501 --logger.level warning > log 2>&1 &
|
11 |
+
echo $! > $DIR/pid
|