Master of Science Updated 2025-07-16
Qijue Updated 2025-07-16
Prussian Academy of Sciences Updated 2025-07-16
Year 1 of the mathematics course of the University of Oxford Updated 2025-07-16
Protein of unknown function Updated 2025-07-16
OurBigBook.com Venture capital Updated 2025-07-16
Not a fun of giving up control for such a low-maintenance cost venture... but keeping a list just in case...
Modular exponentiation Updated 2025-10-14
Can be calculated efficiently with the Extended Euclidean algorithm.
The beauty of this algorithm is that because exponentiation grows really fast, there is no hope that we can ever learn all the digits of an exponential, as there is simply not enough time or memory for that. Therefore, a natural sub-question is if we can know some part of that number, and knowing the smallest digits is the most natural version of that question.
Video file format Updated 2025-07-16
Qsynth Updated 2025-07-16
Qt front-end for FluidSynth.
Model organism Updated 2025-07-16
- prokaryote models:
- E. Coli: the most well studied
- mycoplasma: a very minimal genus, notable species: Mycoplasma genitalium
- eukaryote
- S. cerevisiae: simplest eukaryote model. Unicellular.
- C. elegans: simplest multicellular organism model
- vertebrate:
- Zebrafish: simplest vertebrate model
- mammal:
- Mus musculus: simplest mammal model
Mars sample-return mission Updated 2025-07-16
Mars exploration Updated 2025-07-16
markdownlint/markdownlint Updated 2025-07-16
List of file formats Updated 2025-07-16
Japanese film Updated 2025-07-16
Harry Potter Updated 2025-07-16
Data file format Updated 2025-07-16
Climatology Updated 2025-07-16
Paper by Erwin Schrödinger Updated 2025-09-09
runwayml/stable-diffusion Updated 2025-07-16
Someone should package this better for end user "just works after Conda install" image generation, it is currently much more of a library setup.
Tested on Amazon EC2 on a g5.xlarge machine, which has an Nvidia A10G, using the AWS Deep Learning Base GPU AMI (Ubuntu 20.04) image.
First install Conda as per Section "Install Conda on Ubuntu", and then just follow the instructions from the README, notably the Reference sampling script section.This took about 2 minutes and generated 6 images under
git clone https://github.com/runwayml/stable-diffusion
cd stable-diffusion/
git checkout 08ab4d326c96854026c4eb3454cd3b02109ee982
conda env create -f environment.yaml
conda activate ldm
mkdir -p models/ldm/stable-diffusion-v1/
wget -O models/ldm/stable-diffusion-v1/model.ckpt https://huggingface.co/CompVis/stable-diffusion-v-1-4-original/resolve/main/sd-v1-4.ckpt
python scripts/txt2img.py --prompt "a photograph of an astronaut riding a horse" --plmsoutputs/txt2img-samples/samples, includining an image outputs/txt2img-samples/grid-0000.png which is a grid montage containing all the six images in one:A quick attempt at removing their useless safety features (watermark and NSFW text filter) is:but that produced 4 black images and only two unfiltered ones. Also likely the lack of sexual training data makes its porn suck, and not in the good way.
diff --git a/scripts/txt2img.py b/scripts/txt2img.py
index 59c16a1..0b8ef25 100644
--- a/scripts/txt2img.py
+++ b/scripts/txt2img.py
@@ -87,10 +87,10 @@ def load_replacement(x):
def check_safety(x_image):
safety_checker_input = safety_feature_extractor(numpy_to_pil(x_image), return_tensors="pt")
x_checked_image, has_nsfw_concept = safety_checker(images=x_image, clip_input=safety_checker_input.pixel_values)
- assert x_checked_image.shape[0] == len(has_nsfw_concept)
- for i in range(len(has_nsfw_concept)):
- if has_nsfw_concept[i]:
- x_checked_image[i] = load_replacement(x_checked_image[i])
+ #assert x_checked_image.shape[0] == len(has_nsfw_concept)
+ #for i in range(len(has_nsfw_concept)):
+ # if has_nsfw_concept[i]:
+ # x_checked_image[i] = load_replacement(x_checked_image[i])
return x_checked_image, has_nsfw_concept
@@ -314,7 +314,7 @@ def main():
for x_sample in x_checked_image_torch:
x_sample = 255. * rearrange(x_sample.cpu().numpy(), 'c h w -> h w c')
img = Image.fromarray(x_sample.astype(np.uint8))
- img = put_watermark(img, wm_encoder)
+ # img = put_watermark(img, wm_encoder)
img.save(os.path.join(sample_path, f"{base_count:05}.png"))
base_count += 1 There are unlisted articles, also show them or only show them.
