Introduction
Introduction Statistics Contact Development Disclaimer Help
stable-diffusion-emoji: combine sed invocations - annna - Annna the nice friend…
git clone git://bitreich.org/annna/ git://enlrupgkhuxnvlhsf6lc3fziv5h2hhfrinws6…
Log
Files
Refs
Tags
README
---
commit 67f879460203275681566c60d82ed5be47ade596
parent b5356e361df32026cd51a1570798863bcad6eb3d
Author: Anders Damsgaard <[email protected]>
Date: Fri, 27 Oct 2023 22:11:43 +0200
stable-diffusion-emoji: combine sed invocations
also minor cleanup
Signed-off-by: Annna Robert-Houdin <[email protected]>
Diffstat:
M stable-diffusion-emoji | 12 +-----------
1 file changed, 1 insertion(+), 11 deletions(-)
---
diff --git a/stable-diffusion-emoji b/stable-diffusion-emoji
@@ -14,14 +14,7 @@ emojiuribase="gophers://bitreich.org/9/emoji"
emojistr="$@"
emojiprompt="$(printf "%s\n" "${emojistr}" \
- | sed 's,^::,,' \
- | sed 's,::$,,' \
- | sed 's|,| |g' \
- | sed 's|:| |g' \
- | sed 's|=| |g' \
- | sed 's|/| |g' \
- | sed 's|-| |g' \
- | sed 's|\.| |g')"
+ | sed 's,^::,,; s,::$,,; s|[-,:=/\.]| |g' \
emojifile="$(printf "%s\n" "${emojiprompt}" \
| cut -c -64 \
| sed 's, ,-,g').png"
@@ -30,10 +23,7 @@ emojifile="$(printf "%s\n" "${emojiprompt}" \
if [ ! -e "${emojidb}/${emojifile}" ];
then
- #SD_MODEL="/br/ai/stable-diffusion.cpp/models/stable-diffusion-nano-2-…
- #SD_MODEL="/br/ai/stable-diffusion.cpp/models/lazymixRealAmateur_v30b-…
SD_MODEL="/br/ai/stable-diffusion.cpp/models/epicphotogasm_x-ggml-mode…
stable-diffusion "${emojidb}/${emojifile}" "${emojiprompt}"
fi
[ $? -eq 0 ] && printf "gophers://bitreich.org/9/emoji/%s\n" "${emojifile}"
-
You are viewing proxied material from bitreich.org. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.