Skip to content

Instantly share code, notes, and snippets.

@josephrocca
josephrocca / chroma_diffusers.py
Last active May 29, 2025 02:24
Chroma Diffusers Inference Code (working, but *unoptimized* - about 30s on 4090 for 1024px)
# docker run --rm -it --gpus all -v /home/USER/Desktop/chroma:/workspace -w /workspace pytorch/pytorch:2.6.0-cuda12.6-cudnn9-devel bash
# export HF_HOME=/workspace/cache/huggingface
# pip3 install diffusers==0.32.2 transformers==4.49.0 para-attn==0.3.22 pillow==11.1.0 optimum-quanto==0.2.7 scipy==1.15.2 sentencepiece==0.2.0 protobuf==6.30.1 accelerate==1.5.2
# # Apply some patches to diffusers. First is a bugfix (next diffusers release will have this fix), the rest are to allow negative prompts for Chroma, since diffusers assumes that positive and negative prompts are same length: https://github.com/huggingface/diffusers/pull/11120
# DIFFUSERS_PATH=$(python -c "import diffusers; print(diffusers.__path__[0])")
# sed -i 's/do_true_cfg = true_cfg_scale > 1 and negative_prompt is not None$/do_true_cfg = true_cfg_scale > 1 and negative_prompt is not None or ( negative_prompt_embeds is not None and negative_pooled_prompt_embeds is not None )/' "$DIFFUSERS_PATH/pipelines/flux/pipeline_flux.py"
# sed -i '/ i
Begin by enclosing all thoughts within <thinking> tags, exploring multiple angles and approaches.
Break down the solution into clear steps within <step> tags. Start with a 20-step budget, requesting more for complex problems if needed.
Use <count> tags after each step to show the remaining budget. Stop when reaching 0.
Continuously adjust your reasoning based on intermediate results and reflections, adapting your strategy as you progress.
Regularly evaluate progress using <reflection> tags. Be critical and honest about your reasoning process.
Assign a quality score between 0.0 and 1.0 using <reward> tags after each reflection. Use this to guide your approach:
0.8+: Continue current approach
0.5-0.7: Consider minor adjustments
Below 0.5: Seriously consider backtracking and trying a different approach
@bivoje
bivoje / TIS-100_Reference_Manual_kor.md
Last active December 6, 2024 07:55
Markdown 포맷으로 변환된 TIS-100 매뉴얼 한국어 번역

TIS-100

Tessellated Intelligence System


레퍼런스 매뉴얼

음--

@gboudreau
gboudreau / AuthyToOtherAuthenticator.md
Last active May 28, 2025 09:41 — forked from Ingramz/AuthyToOtherAuthenticator.md
Export TOTP tokens from Authy

Exporting your 2FA tokens from Authy to transfer them into another 2FA application

IMPORTANT - Update regarding deprecation of Authy desktop apps

Past August 2024, Authy stopped supported the desktop version of their apps:
See Authy is shutting down its desktop app | The 2FA app Authy will only be available on Android and iOS starting in August for details.

And indeed, after a while, Authy changed something in their backend which now prevents the old desktop app from logging in. If you are already logged in, then you are in luck, and you can follow the instructions below to export your tokens.

If you are not logged in anymore, but can find a backup of the necessary files, then restore those files, and re-install Authy 2.2.3 following the instructions below, and it should work as expected.