Spaces:
Build error
Build error
Commit
·
1ce0ef5
1
Parent(s):
cf89e54
fix docker, links
Browse files- Dockerfile +1 -4
- app.py +11 -4
Dockerfile
CHANGED
|
@@ -1,14 +1,12 @@
|
|
| 1 |
FROM continuumio/miniconda3
|
| 2 |
|
| 3 |
-
WORKDIR /
|
| 4 |
|
| 5 |
RUN apt-get update && apt-get install --no-install-recommends -y \
|
| 6 |
build-essential \
|
| 7 |
libxml2 \
|
| 8 |
&& apt-get clean && rm -rf /var/lib/apt/lists/*
|
| 9 |
|
| 10 |
-
COPY ./requirements.txt /code/requirements.txt
|
| 11 |
-
|
| 12 |
# Install dependencies
|
| 13 |
RUN conda create -n pose python=3.8
|
| 14 |
|
|
@@ -23,7 +21,6 @@ RUN conda install -c conda-forge cudatoolkit-dev -y
|
|
| 23 |
ENV CUDA_HOME=$CONDA_PREFIX/pkgs/cuda-toolkit/
|
| 24 |
RUN pip install "git+https://github.com/facebookresearch/pytorch3d.git@stable"
|
| 25 |
|
| 26 |
-
|
| 27 |
RUN wget https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0/resolve/main/sd_xl_base_1.0.safetensors -P pretrained_models
|
| 28 |
RUN wget https://huggingface.co/stabilityai/sdxl-vae/resolve/main/sdxl_vae.safetensors -P pretrained_models
|
| 29 |
|
|
|
|
| 1 |
FROM continuumio/miniconda3
|
| 2 |
|
| 3 |
+
WORKDIR /
|
| 4 |
|
| 5 |
RUN apt-get update && apt-get install --no-install-recommends -y \
|
| 6 |
build-essential \
|
| 7 |
libxml2 \
|
| 8 |
&& apt-get clean && rm -rf /var/lib/apt/lists/*
|
| 9 |
|
|
|
|
|
|
|
| 10 |
# Install dependencies
|
| 11 |
RUN conda create -n pose python=3.8
|
| 12 |
|
|
|
|
| 21 |
ENV CUDA_HOME=$CONDA_PREFIX/pkgs/cuda-toolkit/
|
| 22 |
RUN pip install "git+https://github.com/facebookresearch/pytorch3d.git@stable"
|
| 23 |
|
|
|
|
| 24 |
RUN wget https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0/resolve/main/sd_xl_base_1.0.safetensors -P pretrained_models
|
| 25 |
RUN wget https://huggingface.co/stabilityai/sdxl-vae/resolve/main/sdxl_vae.safetensors -P pretrained_models
|
| 26 |
|
app.py
CHANGED
|
@@ -187,7 +187,7 @@ BASE_CONFIG = "configs/train_co3d_concept.yaml"
|
|
| 187 |
BASE_CKPT = "pretrained-models/sd_xl_base_1.0.safetensors"
|
| 188 |
|
| 189 |
start_time = time.time()
|
| 190 |
-
base_model = load_base_model(BASE_CONFIG, ckpt=BASE_CKPT, verbose=False)
|
| 191 |
print(f"Time taken to load base model: {time.time() - start_time:.2f}s")
|
| 192 |
|
| 193 |
global curr_camera_dict
|
|
@@ -327,17 +327,24 @@ with gr.Blocks(head=head,
|
|
| 327 |
gr.HTML("""
|
| 328 |
<div style="display: flex; justify-content: center; align-items: center; text-align: center;">
|
| 329 |
<div>
|
| 330 |
-
<
|
| 331 |
</div>
|
| 332 |
</div>
|
| 333 |
-
<div>
|
| 334 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 335 |
</div>
|
| 336 |
<hr></hr>
|
| 337 |
""",
|
| 338 |
visible=True
|
| 339 |
)
|
| 340 |
|
|
|
|
|
|
|
| 341 |
|
| 342 |
if SPACE_ID == ORIGINAL_SPACE_ID:
|
| 343 |
gr.Markdown(SHARED_UI_WARNING)
|
|
|
|
| 187 |
BASE_CKPT = "pretrained-models/sd_xl_base_1.0.safetensors"
|
| 188 |
|
| 189 |
start_time = time.time()
|
| 190 |
+
# base_model = load_base_model(BASE_CONFIG, ckpt=BASE_CKPT, verbose=False)
|
| 191 |
print(f"Time taken to load base model: {time.time() - start_time:.2f}s")
|
| 192 |
|
| 193 |
global curr_camera_dict
|
|
|
|
| 327 |
gr.HTML("""
|
| 328 |
<div style="display: flex; justify-content: center; align-items: center; text-align: center;">
|
| 329 |
<div>
|
| 330 |
+
<h2><a href='https://customdiffusion360.github.io/index.html'>Customizing Text-to-Image Diffusion with Camera Viewpoint Control</a></h2>
|
| 331 |
</div>
|
| 332 |
</div>
|
| 333 |
+
<div style="display: flex; justify-content: center; align-items: center; text-align: center;">
|
| 334 |
+
<a href='https://customdiffusion360.github.io/index.html' style="padding: 10px;">
|
| 335 |
+
<img src='https://img.shields.io/badge/Project%20Page-8A2BE2'>
|
| 336 |
+
</a>
|
| 337 |
+
<a class="link" href='https://github.com/customdiffusion360/custom-diffusion360' style="padding: 10px;">
|
| 338 |
+
<img src='https://img.shields.io/badge/Github-%23121011.svg'>
|
| 339 |
+
</a>
|
| 340 |
</div>
|
| 341 |
<hr></hr>
|
| 342 |
""",
|
| 343 |
visible=True
|
| 344 |
)
|
| 345 |
|
| 346 |
+
gr
|
| 347 |
+
|
| 348 |
|
| 349 |
if SPACE_ID == ORIGINAL_SPACE_ID:
|
| 350 |
gr.Markdown(SHARED_UI_WARNING)
|