AlekseyCalvin's picture
Update README.md
e2872da verified
|
raw
history blame
7.18 kB
metadata
license: apache-2.0
tags:
  - text-to-image
  - flux
  - flux schnell
  - image-generation
  - flux-diffusers
  - FluxPipeline
  - diffusers
  - photo
  - realism
pipeline_tag: text-to-image
emoji: 🔜
language:
  - en
base_model: black-forest-labs/FLUX.1-schnell
instance_prompt: HST autochrome photo
widget:
  - text: >-
      hst style autochrome film photograph portrait of 1910 woman playing poker
      against a purple feathered dinosaur, the green-eyed woman has moderately
      blemished skin with visible lines and pores, she smiles, film grain,
      Kodachrome
    output:
      url: Historic3.png
  - text: >-
      film photograph portrait of blonde woman dancing with a purple feathered
      dinosaur, the green-eyed woman has moderately blemished skin with visible
      lines and pores, she smiles, film grain, Kodachrome
    output:
      url: Historic4.png
Prompt
HST style autochrome film photograph portrait of 1910 woman playing poker against a purple feathered dinosaur, the green-eyed woman has moderately blemished skin with visible lines and pores, she smiles, film grain, Kodachrome
Prompt
film photograph portrait of a woman
Prompt
film photograph portrait of blonde woman dancing with a purple feathered dinosaur, the green-eyed woman has moderately blemished skin with visible lines and pores, she smiles, film grain, Kodachrome
# **Historic Color Soon® (by A.C.T. Soon®)**
Herein lives a versatile visual + textographic generative model especially catered to:
- Quality generation at a low step-count (2 to 8, for most scenarios), with 4-step inference at around 768x768 routinely producing photorealistic outputs at a quality comparable to or even surpassing that of Flux v.1 Dev.
- Producing realistic images reminiscent of color film analog photography, exhibiting parallels to a broad spectrum of iconic instrumentalities and visual paradigms, from Autochrome-to-Kodachrome-to-Fujifilm-and-beyond.
- Producing visuals with a vaguely "historical" or "lived-in" aesthetic character, striking chromaticity and luminosity dynamics, as well as textural/anatomical/skin details more reliably lifelike than other models at a comparable step-count/resource expenditure.

Foundations/Methods/Tools:

  • Primary Base Model: FLUX.1-schnell by Black Forest Labs.
  • Secondary Base Model: Pixelwave Schnell V.1 and at CivitAI by HumbleMikey.
  • Finetuning (of Pixelwave Schnell V.1), mainly on around 500 color photographs taken during the 1900s and 1910s by Sergey Prokudin-Gorsky, who traveled and photographed widely in those years while pioneering and perfecting implementations of an early three-color-composite photography technique.
    We urge you to explore the work of Prokudin-Gorsky for yourself, at the wonderfully organized online archive at this link, featuring many hundreds of high quality downloadable scans of composite color photo prints from the photographer's original glass plate negatives, available at this site alongside relatively recent restorations of a substantial portion of the images.
    The original glass-plate negatives, alongside a large archive of prints (and other relevant artifacts, documents, and exhibits) are currently held at and administrated by the Library of Congress in Washington, DC, USA.
  • Full-rank LoRA fine-tuning of FLUX.1-schnell on 130 photographs from the same dataset, to create the first LoRA prefiguration of this model: the Historic Color Schnell LoRA.
  • Experiments with training five more LoRAs, using similar datasets, and targetting only select blocks in Schnell (and/or Dev).
  • Merging the most successful among the latter results with Historic Color Schnell LoRA, using the 'flux_merge_lora.py' script from the sd3-branch /networks of Kohya-ss's sd-scripts git, whilst – wherever neccessary – converting the LoRAs (between ai-toolkit/Diffusers-adjacent and the Kohya/sd-scripts formats) using the 'convert_flux_lora.py' script at the same source.
  • Merging the resulting LoRa into the checkpoint finetuned earlier from Pixelwave Schnell v.1.
  • Ostris' training adapter for Schnell found here: ostris/FLUX.1-schnell-training-adapter.

Trigger words

You may use HST to bolster the vintage/autochrome effect. Though, in contrast with the Historic Color LoRA(s), the trigger does not appear to be quite as impactful towards the checkpoint.

Historical Note

Prokudin-Gorsky's color photography technique would involve three photo-exposures, either simultaneous or sequential, using specialized color-spectrum filters (basically R.B.G.: red, blue, and green), rendering the same subject/shot onto glass plates covered with light-emulsive mixture.
The photographer's focus on refining the developer and filter quality, in tandem with his incessant and wide-ranging experimentation, and his persistent usage of glass plates (unwieldly and increasingly old-fashioned, but elsewise extra reliable) ultimately led him to produce a color photography oeuvre of much greater fidelity and vividness than achieved by most of his contemporaries.

At the same time, the peculiarities of the photographer's method, coupled with his exceptionally hands-on execution thereof, would manifest in a range of idyosyncratic color, light, and motion artifacts common across the resulting prints.

Seldom marring the image as a whole, and less grave than the weaknesses of some contemporenously emerging autochrome techniques, the warm color hazes and flares framing many of Prokudin-Gorsky's prints may be seen as a kind of ephemeral signature.
Alongside some of the more subtle chromatic, textural, and (in some measure) figural characteristics of his work, these auras have reliably imprinted themselves into this Flux Schnell LoRA, the fourth in our series of historical adapters for Flux.

film photograph portrait of blonde woman with a dinosaur, the green-eyed woman has moderately blemished skin with visible lines and pores, she smiles, film grain

Download model

Weights for 'Historic Color SOON®' are available in Safetensors format in a separate repo. Download them in the Files & versions tab.

The model is available in 🧨 Diffusers format within this repo.

Diffusers

To use Historic Color SOON® with the 🧨 diffusers python library, first install or upgrade diffusers

pip install -U diffusers

Then you can use FluxPipeline to run the model

import torch
from diffusers import FluxPipeline

pipe = FluxPipeline.from_pretrained("Shakker-Labs/AWPortrait-FL", torch_dtype=torch.bfloat16)
pipe.to("cuda")
pipe.enable_model_cpu_offload() #save some VRAM by offloading the model to CPU. Remove this if you have enough GPU power

prompt = "A cat holding a sign that says hello world"
image = pipe(
    prompt,
    guidance_scale=0.0,
    num_inference_steps=4,
    max_sequence_length=256,
    generator=torch.Generator("cpu").manual_seed(0)
).images[0]
image.save("flux-schnell.png")

To learn more check out the diffusers documentation