Commit cdaab233 authored by AUTOMATIC's avatar AUTOMATIC

Merge remote-tracking branch 'origin/master'

parents 6d2eb339 56b0b0fe
This diff is collapsed.
...@@ -357,6 +357,9 @@ def save_image(image, path, basename, seed=None, prompt=None, extension='png', i ...@@ -357,6 +357,9 @@ def save_image(image, path, basename, seed=None, prompt=None, extension='png', i
else: else:
image.save(fullfn, quality=opts.jpeg_quality, pnginfo=pnginfo) image.save(fullfn, quality=opts.jpeg_quality, pnginfo=pnginfo)
if extension.lower() == "webp":
piexif.insert(exif_bytes, fullfn)
target_side_length = 4000 target_side_length = 4000
oversize = image.width > target_side_length or image.height > target_side_length oversize = image.width > target_side_length or image.height > target_side_length
if opts.export_for_4chan and (oversize or os.stat(fullfn).st_size > 4 * 1024 * 1024): if opts.export_for_4chan and (oversize or os.stat(fullfn).st_size > 4 * 1024 * 1024):
......
...@@ -57,7 +57,7 @@ def split_cross_attention_forward(self, x, context=None, mask=None): ...@@ -57,7 +57,7 @@ def split_cross_attention_forward(self, x, context=None, mask=None):
q, k, v = map(lambda t: rearrange(t, 'b n (h d) -> (b h) n d', h=h), (q_in, k_in, v_in)) q, k, v = map(lambda t: rearrange(t, 'b n (h d) -> (b h) n d', h=h), (q_in, k_in, v_in))
del q_in, k_in, v_in del q_in, k_in, v_in
r1 = torch.zeros(q.shape[0], q.shape[1], v.shape[2], device=q.device) r1 = torch.zeros(q.shape[0], q.shape[1], v.shape[2], device=q.device, dtype=q.dtype)
stats = torch.cuda.memory_stats(q.device) stats = torch.cuda.memory_stats(q.device)
mem_active = stats['active_bytes.all.current'] mem_active = stats['active_bytes.all.current']
......
...@@ -16,7 +16,7 @@ export COMMANDLINE_ARGS=() ...@@ -16,7 +16,7 @@ export COMMANDLINE_ARGS=()
python_cmd="python3" python_cmd="python3"
# git executable # git executable
export GIT="" #export GIT=""
# python3 venv without trailing slash (defaults to ${install_dir}/${clone_dir}/venv) # python3 venv without trailing slash (defaults to ${install_dir}/${clone_dir}/venv)
venv_dir="venv" venv_dir="venv"
...@@ -25,16 +25,16 @@ venv_dir="venv" ...@@ -25,16 +25,16 @@ venv_dir="venv"
export TORCH_COMMAND=(python3 -m pip install torch==1.12.1+cu113 --extra-index-url https://download.pytorch.org/whl/cu113) export TORCH_COMMAND=(python3 -m pip install torch==1.12.1+cu113 --extra-index-url https://download.pytorch.org/whl/cu113)
# Requirements file to use for stable-diffusion-webui # Requirements file to use for stable-diffusion-webui
export REQS_FILE="" #export REQS_FILE=""
# Fixed git repos # Fixed git repos
export K_DIFFUSION_PACKAGE="" #export K_DIFFUSION_PACKAGE=""
export GFPGAN_PACKAGE="" #export GFPGAN_PACKAGE=""
# Fixed git commits # Fixed git commits
export STABLE_DIFFUSION_COMMIT_HASH="" #export STABLE_DIFFUSION_COMMIT_HASH=""
export TAMING_TRANSFORMERS_COMMIT_HASH="" #export TAMING_TRANSFORMERS_COMMIT_HASH=""
export CODEFORMER_COMMIT_HASH="" #export CODEFORMER_COMMIT_HASH=""
export BLIP_COMMIT_HASH="" #export BLIP_COMMIT_HASH=""
########################################### ###########################################
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment