cuda
Browse files- Dockerfile +1 -1
- main.py +14 -12
Dockerfile
CHANGED
@@ -4,7 +4,7 @@ WORKDIR /code
|
|
4 |
COPY ./requirements.txt /code/requirements.txt
|
5 |
|
6 |
#RUN pip install torch==1.9.1+cu111 torchvision==0.10.1+cu111 -f https://download.pytorch.org/whl/torch_stable.ht
|
7 |
-
RUN pip install torch==1.9.1 torchvision==0.10.1 -f https://download.pytorch.org/whl/cu111
|
8 |
#https://download.pytorch.org/whl/torch_stable.ht
|
9 |
RUN pip install --no-cache-dir --upgrade -U openmim
|
10 |
RUN mim install --no-cache-dir --upgrade mmengine
|
|
|
4 |
COPY ./requirements.txt /code/requirements.txt
|
5 |
|
6 |
#RUN pip install torch==1.9.1+cu111 torchvision==0.10.1+cu111 -f https://download.pytorch.org/whl/torch_stable.ht
|
7 |
+
RUN pip install torch==1.9.1 torchvision==0.10.1 -f https://download.pytorch.org/whl/torch_stable.ht -extra-index-url https://download.pytorch.org/whl/cu111
|
8 |
#https://download.pytorch.org/whl/torch_stable.ht
|
9 |
RUN pip install --no-cache-dir --upgrade -U openmim
|
10 |
RUN mim install --no-cache-dir --upgrade mmengine
|
main.py
CHANGED
@@ -179,19 +179,21 @@ def pose2dhand(video, kpt_threshold):
|
|
179 |
|
180 |
def run_UI():
|
181 |
with gr.Blocks() as demo:
|
182 |
-
with gr.Column():
|
183 |
with gr.Tab("Upload video"):
|
184 |
-
with gr.
|
185 |
-
with gr.
|
186 |
-
|
187 |
-
|
188 |
-
|
189 |
-
|
190 |
-
|
191 |
-
|
192 |
-
|
193 |
-
|
194 |
-
|
|
|
|
|
195 |
video_output1 = gr.PlayableVideo(height=512, label = "Estimate human 2d poses", show_label=True)
|
196 |
video_output2 = gr.PlayableVideo(height=512, label = "Estimate human 3d poses", show_label=True)
|
197 |
video_output3 = gr.PlayableVideo(height=512, label = "Estimate human hand poses", show_label=True)
|
|
|
179 |
|
180 |
def run_UI():
|
181 |
with gr.Blocks() as demo:
|
182 |
+
with gr.Column():
|
183 |
with gr.Tab("Upload video"):
|
184 |
+
with gr.Column():
|
185 |
+
with gr.Row():
|
186 |
+
with gr.Column():
|
187 |
+
video_input = gr.Video(source="upload", type="filepath", height=612)
|
188 |
+
# Insert slider with kpt_thr
|
189 |
+
file_kpthr = gr.Slider(minimum=0.1, maximum=1, step=20, default=0.3, label='Keypoint threshold')
|
190 |
+
|
191 |
+
submit_pose_file = gr.Button("Make 2d pose estimation")
|
192 |
+
submit_pose3d_file = gr.Button("Make 3d pose estimation")
|
193 |
+
submit_hand_file = gr.Button("Make 2d hand estimation")
|
194 |
+
submit_detect_file = gr.Button("Detect and track objects")
|
195 |
+
|
196 |
+
with gr.Row():
|
197 |
video_output1 = gr.PlayableVideo(height=512, label = "Estimate human 2d poses", show_label=True)
|
198 |
video_output2 = gr.PlayableVideo(height=512, label = "Estimate human 3d poses", show_label=True)
|
199 |
video_output3 = gr.PlayableVideo(height=512, label = "Estimate human hand poses", show_label=True)
|