AI Slop Code Risk Monitor

lllyasviel/Fooocus

SlopCodeMonitor badge for lllyasviel/Fooocus Adjusted legacy signal; badge bands: 25 / 50 / 75 (different from dashboard bands).

Focus on prompting and generating

4.8 Low pattern signal View on GitHub

Open-Source Code Quality, Security and Technical Debt Review

This report summarizes scanner evidence for lllyasviel/Fooocus, a Python project with 53,977 GitHub stars. SynthScan examined 193,544 lines of code across 281 source files, recording 599 pattern matches distributed across 16 syntactic categories. The legacy adjusted pattern signal is 4.8 (Low pattern signal); it is not an authorship estimate.

Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.

4.8
Adjusted Signal
4.8
Raw Pattern Score
100%
Time Factor
2025-12-01
Last Push
54.0K
Stars
Python
Language
193.5K
Lines of Code
281
Files
599
Pattern Hits
2026-11-27
Scan Date
0.25
HC Hit Rate

Risk Review · Payload v1

Use each vector to guide manual verification of the underlying findings.

Payload schema: 1.0.0 · Engine: 2.0.0 · Scoring: heuristic-density-v1 · Scan date: 2026-11-27.

Cognitive Ownership Risk 10.3/100 · LOW

Can maintainers explain intent, assumptions, and trade-offs? 407 finding(s).

Hallucinated Dependency & Supply Chain Risk 2.6/100 · LOW

Are imports declared and package/API names verified? 83 finding(s).

Agent Over-Engineering Ratio 15.0/100 · LOW

Are wrappers, guards, and repeated structures necessary? 332 finding(s).

PR Review Velocity Impact 22.8/100 · LOW

Which changes need focused human review? 599 finding(s).

What These Metrics Mean

Adjusted Signal
Legacy pattern score normalized per 1,000 scanned lines and multiplied by the repository-level time factor. It is not an estimate of AI authorship.
Raw Pattern Score
Sum of severity- and context-weighted pattern findings before applying the time factor.
Time Factor
A coarse multiplier based on repository last-push metadata. It does not identify when individual code was written.
Pattern Hits
Count of configured pattern findings. Review each location and surrounding code before acting.
HC Hit Rate
High- and critical-severity findings per scanned file. Severity is a configured detector weight, not proof of a vulnerability or authorship.
Lines / Files
Scan coverage denominators used by the legacy normalized score.

Pattern-Signal History

Run additional scans to build a history of the legacy pattern signal. Score changes are not a measure of AI adoption or code quality.

No multi-scan history yet — run the scanner again to build trend data.

Severity Breakdown

Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.

CRITICAL 2HIGH 68MEDIUM 21LOW 508

Directory Score Breakdown

This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.

Pattern Findings

The scanner identified 599 distinct pattern matches across 16 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.

Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.

Cross-File Repetition55 hits · 275 pts
SeverityFileLineSnippetContext
HIGHldm_patched/pfn/architecture/Swin2SR.py0args: x: (b, h, w, c) window_size (int): window size returns: windows: (num_windows*b, window_size, window_size, c)STRING
HIGHldm_patched/pfn/architecture/HAT.py0args: x: (b, h, w, c) window_size (int): window size returns: windows: (num_windows*b, window_size, window_size, c)STRING
HIGHldm_patched/pfn/architecture/SwinIR.py0args: x: (b, h, w, c) window_size (int): window size returns: windows: (num_windows*b, window_size, window_size, c)STRING
HIGHldm_patched/pfn/architecture/Swin2SR.py0args: windows: (num_windows*b, window_size, window_size, c) window_size (int): window size h (int): height of image w (iSTRING
HIGHldm_patched/pfn/architecture/HAT.py0args: windows: (num_windows*b, window_size, window_size, c) window_size (int): window size h (int): height of image w (iSTRING
HIGHldm_patched/pfn/architecture/SwinIR.py0args: windows: (num_windows*b, window_size, window_size, c) window_size (int): window size h (int): height of image w (iSTRING
HIGHldm_patched/pfn/architecture/Swin2SR.py0args: x: input features with shape of (num_windows*b, n, c) mask: (0/-inf) mask with shape of (num_windows, wh*ww, wh*wwSTRING
HIGHldm_patched/pfn/architecture/HAT.py0args: x: input features with shape of (num_windows*b, n, c) mask: (0/-inf) mask with shape of (num_windows, wh*ww, wh*wwSTRING
HIGHldm_patched/pfn/architecture/SwinIR.py0args: x: input features with shape of (num_windows*b, n, c) mask: (0/-inf) mask with shape of (num_windows, wh*ww, wh*wwSTRING
HIGHldm_patched/pfn/architecture/Swin2SR.py0patch merging layer. args: input_resolution (tuple[int]): resolution of input feature. dim (int): number of input channeSTRING
HIGHldm_patched/pfn/architecture/HAT.py0patch merging layer. args: input_resolution (tuple[int]): resolution of input feature. dim (int): number of input channeSTRING
HIGHldm_patched/pfn/architecture/SwinIR.py0patch merging layer. args: input_resolution (tuple[int]): resolution of input feature. dim (int): number of input channeSTRING
HIGHldm_patched/pfn/architecture/Swin2SR.py0a basic swin transformer layer for one stage. args: dim (int): number of input channels. input_resolution (tuple[int]): STRING
HIGHldm_patched/pfn/architecture/HAT.py0a basic swin transformer layer for one stage. args: dim (int): number of input channels. input_resolution (tuple[int]): STRING
HIGHldm_patched/pfn/architecture/SwinIR.py0a basic swin transformer layer for one stage. args: dim (int): number of input channels. input_resolution (tuple[int]): STRING
HIGHldm_patched/pfn/architecture/Swin2SR.py0image to patch unembedding args: img_size (int): image size. default: 224. patch_size (int): patch token size. default: STRING
HIGHldm_patched/pfn/architecture/HAT.py0image to patch unembedding args: img_size (int): image size. default: 224. patch_size (int): patch token size. default: STRING
HIGHldm_patched/pfn/architecture/SwinIR.py0image to patch unembedding args: img_size (int): image size. default: 224. patch_size (int): patch token size. default: STRING
HIGHldm_patched/pfn/architecture/Swin2SR.py0residual swin transformer block (rstb). args: dim (int): number of input channels. input_resolution (tuple[int]): input STRING
HIGHldm_patched/pfn/architecture/HAT.py0residual swin transformer block (rstb). args: dim (int): number of input channels. input_resolution (tuple[int]): input STRING
HIGHldm_patched/pfn/architecture/SwinIR.py0residual swin transformer block (rstb). args: dim (int): number of input channels. input_resolution (tuple[int]): input STRING
HIGHldm_patched/pfn/architecture/Swin2SR.py0upsample module. args: scale (int): scale factor. supported scales: 2^n and 3. num_feat (int): channel number of intermeSTRING
HIGHldm_patched/pfn/architecture/DAT.py0upsample module. args: scale (int): scale factor. supported scales: 2^n and 3. num_feat (int): channel number of intermeSTRING
HIGHldm_patched/pfn/architecture/HAT.py0upsample module. args: scale (int): scale factor. supported scales: 2^n and 3. num_feat (int): channel number of intermeSTRING
HIGHldm_patched/pfn/architecture/SwinIR.py0upsample module. args: scale (int): scale factor. supported scales: 2^n and 3. num_feat (int): channel number of intermeSTRING
HIGHldm_patched/pfn/architecture/Swin2SR.py0upsampleonestep module (the difference with upsample is that it always only has 1conv + 1pixelshuffle) used in lightweigSTRING
HIGHldm_patched/pfn/architecture/DAT.py0upsampleonestep module (the difference with upsample is that it always only has 1conv + 1pixelshuffle) used in lightweigSTRING
HIGHldm_patched/pfn/architecture/SwinIR.py0upsampleonestep module (the difference with upsample is that it always only has 1conv + 1pixelshuffle) used in lightweigSTRING
HIGH…tched/pfn/architecture/face/stylegan2_bilinear_arch.py0normalize the style codes. args: x (tensor): style codes with shape (b, c). returns: tensor: normalized tensor.STRING
HIGH…_patched/pfn/architecture/face/stylegan2_clean_arch.py0normalize the style codes. args: x (tensor): style codes with shape (b, c). returns: tensor: normalized tensor.STRING
HIGHldm_patched/pfn/architecture/face/stylegan2_arch.py0normalize the style codes. args: x (tensor): style codes with shape (b, c). returns: tensor: normalized tensor.STRING
HIGH…tched/pfn/architecture/face/stylegan2_bilinear_arch.py0forward function. args: x (tensor): tensor with shape (b, c, h, w). style (tensor): tensor with shape (b, num_style_featSTRING
HIGH…_patched/pfn/architecture/face/stylegan2_clean_arch.py0forward function. args: x (tensor): tensor with shape (b, c, h, w). style (tensor): tensor with shape (b, num_style_featSTRING
HIGHldm_patched/pfn/architecture/face/stylegan2_arch.py0forward function. args: x (tensor): tensor with shape (b, c, h, w). style (tensor): tensor with shape (b, num_style_featSTRING
HIGH…tched/pfn/architecture/face/stylegan2_bilinear_arch.py0forward function. args: x (tensor): feature tensor with shape (b, c, h, w). style (tensor): tensor with shape (b, num_stSTRING
HIGH…_patched/pfn/architecture/face/stylegan2_clean_arch.py0forward function. args: x (tensor): feature tensor with shape (b, c, h, w). style (tensor): tensor with shape (b, num_stSTRING
HIGHldm_patched/pfn/architecture/face/stylegan2_arch.py0forward function. args: x (tensor): feature tensor with shape (b, c, h, w). style (tensor): tensor with shape (b, num_stSTRING
HIGH…tched/pfn/architecture/face/stylegan2_bilinear_arch.py0constant input. args: num_channel (int): channel number of constant input. size (int): spatial size of constant input.STRING
HIGH…_patched/pfn/architecture/face/stylegan2_clean_arch.py0constant input. args: num_channel (int): channel number of constant input. size (int): spatial size of constant input.STRING
HIGHldm_patched/pfn/architecture/face/stylegan2_arch.py0constant input. args: num_channel (int): channel number of constant input. size (int): spatial size of constant input.STRING
HIGH…tched/pfn/architecture/face/stylegan2_bilinear_arch.py0forward function for stylegan2generatorbilinearsft. args: styles (list[tensor]): sample codes of styles. conditions (lisSTRING
HIGHldm_patched/pfn/architecture/face/stylegan2_arch.py0forward function for stylegan2generatorbilinearsft. args: styles (list[tensor]): sample codes of styles. conditions (lisSTRING
HIGH…_patched/pfn/architecture/face/stylegan2_clean_arch.py0forward function for stylegan2generatorbilinearsft. args: styles (list[tensor]): sample codes of styles. conditions (lisSTRING
HIGHldm_patched/pfn/architecture/face/gfpganv1_arch.py0forward function for stylegan2generatorbilinearsft. args: styles (list[tensor]): sample codes of styles. conditions (lisSTRING
HIGH…m_patched/pfn/architecture/face/gfpganv1_clean_arch.py0forward function for stylegan2generatorbilinearsft. args: styles (list[tensor]): sample codes of styles. conditions (lisSTRING
HIGH…_patched/pfn/architecture/face/gfpgan_bilinear_arch.py0forward function for stylegan2generatorbilinearsft. args: styles (list[tensor]): sample codes of styles. conditions (lisSTRING
HIGHldm_patched/pfn/architecture/face/gfpganv1_arch.py0forward function for gfpganbilinear. args: x (tensor): input images. return_latents (bool): whether to return style lateSTRING
HIGH…m_patched/pfn/architecture/face/gfpganv1_clean_arch.py0forward function for gfpganbilinear. args: x (tensor): input images. return_latents (bool): whether to return style lateSTRING
HIGH…_patched/pfn/architecture/face/gfpgan_bilinear_arch.py0forward function for gfpganbilinear. args: x (tensor): input images. return_latents (bool): whether to return style lateSTRING
HIGHextras/BLIP/models/blip_vqa.py0args: med_config (str): path for the mixture of encoder-decoder model's configuration file image_size (int): input imageSTRING
HIGHextras/BLIP/models/blip.py0args: med_config (str): path for the mixture of encoder-decoder model's configuration file image_size (int): input imageSTRING
HIGHextras/BLIP/models/blip_retrieval.py0args: med_config (str): path for the mixture of encoder-decoder model's configuration file image_size (int): input imageSTRING
HIGHextras/BLIP/models/blip_itm.py0args: med_config (str): path for the mixture of encoder-decoder model's configuration file image_size (int): input imageSTRING
HIGHextras/BLIP/models/blip_nlvr.py0args: med_config (str): path for the mixture of encoder-decoder model's configuration file image_size (int): input imageSTRING
HIGHextras/BLIP/models/blip_pretrain.py0args: med_config (str): path for the mixture of encoder-decoder model's configuration file image_size (int): input imageSTRING
AI Structural Patterns123 hits · 123 pts
SeverityFileLineSnippetContext
LOWldm_patched/k_diffusion/sampling.py479CODE
LOWldm_patched/k_diffusion/sampling.py412CODE
LOWldm_patched/controlnet/cldm.py23CODE
LOWldm_patched/unipc/uni_pc.py181CODE
LOWldm_patched/unipc/uni_pc.py712CODE
LOWldm_patched/contrib/external_rebatch.py56CODE
LOWldm_patched/contrib/external.py577CODE
LOWldm_patched/contrib/external_compositing.py144CODE
LOWldm_patched/contrib/external_compositing.py164CODE
LOWldm_patched/contrib/external_compositing.py190CODE
LOWldm_patched/pfn/architecture/Swin2SR.py273CODE
LOWldm_patched/pfn/architecture/Swin2SR.py504CODE
LOWldm_patched/pfn/architecture/Swin2SR.py660CODE
LOWldm_patched/pfn/architecture/DAT.py309CODE
LOWldm_patched/pfn/architecture/DAT.py683CODE
LOWldm_patched/pfn/architecture/DAT.py773CODE
LOWldm_patched/pfn/architecture/HAT.py28CODE
LOWldm_patched/pfn/architecture/HAT.py252CODE
LOWldm_patched/pfn/architecture/HAT.py558CODE
LOWldm_patched/pfn/architecture/HAT.py665CODE
LOWldm_patched/pfn/architecture/SwinIR.py231CODE
LOWldm_patched/pfn/architecture/SwinIR.py465CODE
LOWldm_patched/pfn/architecture/SwinIR.py564CODE
LOWldm_patched/pfn/architecture/block.py157CODE
LOWldm_patched/pfn/architecture/block.py519CODE
LOWldm_patched/pfn/architecture/block.py83CODE
LOWldm_patched/pfn/architecture/block.py100CODE
LOWldm_patched/pfn/architecture/block.py224CODE
LOWldm_patched/pfn/architecture/block.py292CODE
LOWldm_patched/pfn/architecture/block.py378CODE
LOWldm_patched/pfn/architecture/LaMa.py80CODE
LOWldm_patched/pfn/architecture/LaMa.py84CODE
LOWldm_patched/pfn/architecture/LaMa.py279CODE
LOWldm_patched/pfn/architecture/LaMa.py283CODE
LOWldm_patched/pfn/architecture/LaMa.py392CODE
LOWldm_patched/pfn/architecture/LaMa.py520CODE
LOWldm_patched/pfn/architecture/LaMa.py694CODE
LOWldm_patched/pfn/architecture/OmniSR/OmniSR.py143CODE
LOWldm_patched/pfn/architecture/OmniSR/esa.py216CODE
LOWldm_patched/pfn/architecture/OmniSR/OSA.py374CODE
LOWldm_patched/pfn/architecture/OmniSR/OSA.py434CODE
LOWldm_patched/pfn/architecture/OmniSR/OSA.py494CODE
LOWldm_patched/pfn/architecture/OmniSR/OSA.py577CODE
LOW…tched/pfn/architecture/face/stylegan2_bilinear_arch.py182CODE
LOW…tched/pfn/architecture/face/stylegan2_bilinear_arch.py238CODE
LOW…tched/pfn/architecture/face/stylegan2_bilinear_arch.py306CODE
LOW…tched/pfn/architecture/face/stylegan2_bilinear_arch.py601CODE
LOW…tched/pfn/architecture/face/stylegan2_bilinear_arch.py709CODE
LOWldm_patched/pfn/architecture/face/arcface_arch.py55CODE
LOWldm_patched/pfn/architecture/face/arcface_arch.py103CODE
LOWldm_patched/pfn/architecture/face/arcface_arch.py154CODE
LOW…_patched/pfn/architecture/face/stylegan2_clean_arch.py136CODE
LOW…_patched/pfn/architecture/face/stylegan2_clean_arch.py190CODE
LOW…_patched/pfn/architecture/face/stylegan2_clean_arch.py247CODE
LOWldm_patched/pfn/architecture/face/gfpganv1_arch.py246CODE
LOWldm_patched/pfn/architecture/face/gfpganv1_arch.py268CODE
LOWldm_patched/pfn/architecture/face/restoreformer_arch.py293CODE
LOWldm_patched/pfn/architecture/face/restoreformer_arch.py418CODE
LOWldm_patched/pfn/architecture/face/restoreformer_arch.py545CODE
LOWldm_patched/pfn/architecture/face/upfirdn2d.py119CODE
63 more matches not shown…
Deep Nesting113 hits · 113 pts
SeverityFileLineSnippetContext
LOWwebui.py33CODE
LOWlaunch.py29CODE
LOWlaunch.py103CODE
LOWldm_patched/k_diffusion/sampling.py596CODE
LOWldm_patched/k_diffusion/sampling.py642CODE
LOWldm_patched/k_diffusion/sampling.py842CODE
LOWldm_patched/controlnet/cldm.py23CODE
LOWldm_patched/unipc/uni_pc.py181CODE
LOWldm_patched/unipc/uni_pc.py293CODE
LOWldm_patched/unipc/uni_pc.py322CODE
LOWldm_patched/unipc/uni_pc.py712CODE
LOWldm_patched/contrib/external_hypernetwork.py7CODE
LOWldm_patched/contrib/external_post_processing.py49CODE
LOWldm_patched/contrib/external_post_processing.py168CODE
LOWldm_patched/contrib/external.py1859CODE
LOWldm_patched/contrib/external.py539CODE
LOWldm_patched/contrib/external.py648CODE
LOWldm_patched/contrib/external.py1415CODE
LOWldm_patched/contrib/external.py1686CODE
LOWldm_patched/contrib/external_compositing.py32CODE
LOWldm_patched/contrib/external_model_advanced.py82CODE
LOWldm_patched/contrib/external_mask.py238CODE
LOWldm_patched/t2ia/adapter.py104CODE
LOWldm_patched/pfn/model_loading.py24CODE
LOWldm_patched/pfn/architecture/Swin2SR.py882CODE
LOWldm_patched/pfn/architecture/Swin2SR.py1283CODE
LOWldm_patched/pfn/architecture/SwinIR.py816CODE
LOWldm_patched/pfn/architecture/SwinIR.py1162CODE
LOWldm_patched/pfn/architecture/RRDB.py196CODE
LOWldm_patched/pfn/architecture/SRVGG.py23CODE
LOWldm_patched/pfn/architecture/face/arcface_arch.py195CODE
LOW…_patched/pfn/architecture/face/stylegan2_clean_arch.py13CODE
LOWldm_patched/ldm/util.py119CODE
LOWldm_patched/ldm/modules/attention.py185CODE
LOWldm_patched/ldm/modules/diffusionmodules/util.py87CODE
LOWldm_patched/ldm/modules/diffusionmodules/openaimodel.py32CODE
LOWldm_patched/ldm/modules/diffusionmodules/openaimodel.py391CODE
LOWldm_patched/modules/sd1_clip.py199CODE
LOWldm_patched/modules/sd1_clip.py227CODE
LOWldm_patched/modules/sd1_clip.py257CODE
LOWldm_patched/modules/sd1_clip.py284CODE
LOWldm_patched/modules/sd1_clip.py25CODE
LOWldm_patched/modules/sd1_clip.py117CODE
LOWldm_patched/modules/sd1_clip.py156CODE
LOWldm_patched/modules/sd1_clip.py397CODE
LOWldm_patched/modules/controlnet.py315CODE
LOWldm_patched/modules/controlnet.py86CODE
LOWldm_patched/modules/model_patcher.py118CODE
LOWldm_patched/modules/model_patcher.py215CODE
LOWldm_patched/modules/gligen.py301CODE
LOWldm_patched/modules/model_base.py97CODE
LOWldm_patched/modules/model_detection.py31CODE
LOWldm_patched/modules/utils.py63CODE
LOWldm_patched/modules/utils.py171CODE
LOWldm_patched/modules/utils.py408CODE
LOWldm_patched/modules/lora.py13CODE
LOWldm_patched/modules/lora.py162CODE
LOWldm_patched/modules/lora.py203CODE
LOWldm_patched/modules/sd.py346CODE
LOWldm_patched/modules/sd.py151CODE
53 more matches not shown…
Hyper-Verbose Identifiers100 hits · 108 pts
SeverityFileLineSnippetContext
LOWwebui.py349 def trigger_show_image_properties(image):CODE
LOWwebui.py922 def inpaint_engine_state_change(inpaint_engine_version, *args):CODE
LOWwebui.py1113def dump_default_english_config():CODE
LOWtests/test_utils.py9 def test_can_parse_tokens_with_lora(self):CODE
LOWtests/test_utils.py86 def test_can_parse_tokens_and_strip_performance_lora(self):CODE
LOWldm_patched/k_diffusion/sampling.py31def get_sigmas_polyexponential(n, sigma_min, sigma_max, rho=1., device='cpu'):CODE
LOWldm_patched/unipc/uni_pc.py442 def get_orders_and_timesteps_for_singlestep_solver(self, steps, order, skip_type, t_T, t_0, device):CODE
LOWldm_patched/unipc/uni_pc.py488 def multistep_uni_pc_vary_update(self, x, model_prev_list, t_prev_list, t, order, use_corrector=True):CODE
LOWldm_patched/unipc/uni_pc.py591 def multistep_uni_pc_bh_update(self, x, model_prev_list, t_prev_list, t, order, x_t=None, use_corrector=True):CODE
LOWldm_patched/utils/latent_visualization.py16 def decode_latent_to_preview_image(self, preview_format, x0):CODE
LOWldm_patched/utils/path_utils.py115def exists_annotated_filepath(name):CODE
LOWldm_patched/contrib/external_model_advanced.py50def rescale_zero_terminal_snr_sigmas(sigmas):CODE
LOWldm_patched/pfn/architecture/face/codeformer.py417def adaptive_instance_normalization(content_feat, style_feat):CODE
LOWldm_patched/ldm/models/autoencoder.py88 def instantiate_optimizer_from_config(self, params, lr, cfg):CODE
LOWldm_patched/ldm/modules/attention.py350def optimized_attention_for_device(device, mask=False, small_input=False):CODE
LOWldm_patched/ldm/modules/sub_quadratic_attention.py139def _get_attention_scores_no_kv_chunking(CODE
LOWldm_patched/ldm/modules/sub_quadratic_attention.py187def efficient_dot_product_attention(CODE
LOWldm_patched/ldm/modules/diffusionmodules/util.py136def make_ddim_sampling_parameters(alphacums, ddim_timesteps, eta, verbose=True):CODE
LOWldm_patched/modules/sd1_clip.py117 def set_up_textual_embeddings(self, tokens, current_embeds):CODE
LOWldm_patched/modules/controlnet.py81 def inference_memory_requirements(self, dtype):CODE
LOWldm_patched/modules/controlnet.py312 def inference_memory_requirements(self, dtype):CODE
LOW⚡ldm_patched/modules/model_patcher.py54 def set_model_sampler_cfg_function(self, sampler_cfg_function, disable_cfg1_optimization=False):CODE
LOW⚡ldm_patched/modules/model_patcher.py62 def set_model_sampler_post_cfg_function(self, post_cfg_function, disable_cfg1_optimization=False):CODE
LOW⚡ldm_patched/modules/model_patcher.py67 def set_model_unet_function_wrapper(self, unet_wrapper_function):CODE
LOW⚡ldm_patched/modules/model_patcher.py106 def set_model_input_block_patch(self, patch):CODE
LOW⚡ldm_patched/modules/model_patcher.py109 def set_model_input_block_patch_after_skip(self, patch):CODE
LOW⚡ldm_patched/modules/model_patcher.py112 def set_model_output_block_patch(self, patch):CODE
LOW⚡ldm_patched/modules/supported_models_base.py64 def process_clip_state_dict_for_saving(self, state_dict):CODE
LOW⚡ldm_patched/modules/supported_models_base.py68 def process_clip_vision_state_dict_for_saving(self, state_dict):CODE
LOW⚡ldm_patched/modules/supported_models_base.py74 def process_unet_state_dict_for_saving(self, state_dict):CODE
LOW⚡ldm_patched/modules/supported_models_base.py78 def process_vae_state_dict_for_saving(self, state_dict):CODE
LOWldm_patched/modules/supported_models.py47 def process_clip_state_dict_for_saving(self, state_dict):CODE
LOWldm_patched/modules/supported_models.py81 def process_clip_state_dict_for_saving(self, state_dict):CODE
LOWldm_patched/modules/supported_models.py142 def process_clip_state_dict_for_saving(self, state_dict):CODE
LOWldm_patched/modules/supported_models.py192 def process_clip_state_dict_for_saving(self, state_dict):CODE
LOWldm_patched/modules/diffusers_convert.py258def convert_text_enc_state_dict(text_enc_dict):CODE
LOWldm_patched/modules/ops.py19 def forward_ldm_patched_cast_weights(self, input):CODE
LOWldm_patched/modules/ops.py34 def forward_ldm_patched_cast_weights(self, input):CODE
LOWldm_patched/modules/ops.py49 def forward_ldm_patched_cast_weights(self, input):CODE
LOWldm_patched/modules/ops.py64 def forward_ldm_patched_cast_weights(self, input):CODE
LOWldm_patched/modules/ops.py80 def forward_ldm_patched_cast_weights(self, input):CODE
LOWldm_patched/modules/model_detection.py17def calculate_transformer_depth(prefix, state_dict_keys, state_dict):CODE
LOWldm_patched/modules/model_detection.py154def model_config_from_unet_config(unet_config):CODE
LOWldm_patched/modules/model_detection.py209def unet_config_from_diffusers_unet(state_dict, dtype):CODE
LOWldm_patched/modules/model_detection.py316def model_config_from_diffusers_unet(state_dict, dtype):CODE
LOWldm_patched/modules/utils.py50def state_dict_prefix_replace(state_dict, replace_prefix, filter_keys=False):CODE
LOWldm_patched/modules/utils.py440def set_progress_bar_global_hook(function):CODE
LOWldm_patched/modules/sample.py70def cleanup_additional_models(models):CODE
LOWldm_patched/modules/sd.py430def load_checkpoint_guess_config(ckpt_path, output_vae=True, output_clip=True, output_clipvision=False, embedding_directCODE
LOWldm_patched/modules/samplers.py347def resolve_areas_and_cond_masks(conditions, h, w, device):CODE
LOWldm_patched/modules/samplers.py387def create_cond_with_same_area_if_none(conds, c):CODE
LOWldm_patched/modules/samplers.py419def calculate_start_end_timesteps(model, conds):CODE
LOWldm_patched/modules/samplers.py450def apply_empty_x_to_equal_area(conds, uncond, name, uncond_fill_func):CODE
LOWldm_patched/modules/samplers.py624def calculate_sigmas_scheduler(model, scheduler_name, steps):CODE
LOWldm_patched/modules/model_management.py520def text_encoder_offload_device():CODE
LOWldm_patched/modules/model_management.py594def device_supports_non_blocking(device):CODE
LOWldm_patched/modules/model_management.py640def pytorch_attention_enabled():CODE
LOWldm_patched/modules/model_management.py644def pytorch_attention_flash_attention():CODE
LOWldm_patched/modules/model_management.py789def interrupt_current_processing(value=True):CODE
LOWldm_patched/modules/model_management.py801def throw_exception_if_processing_interrupted():CODE
40 more matches not shown…
Unused Imports80 hits · 80 pts
SeverityFileLineSnippetContext
LOWentry_with_update.py46CODE
LOWlaunch.py152CODE
LOWtests/test_extra_utils.py2CODE
LOWtests/test_extra_utils.py5CODE
LOWldm_patched/controlnet/cldm.py5CODE
LOWldm_patched/controlnet/cldm.py8CODE
LOWldm_patched/unipc/uni_pc.py4CODE
LOWldm_patched/unipc/uni_pc.py7CODE
LOWldm_patched/utils/latent_visualization.py3CODE
LOWldm_patched/contrib/external_sag.py9CODE
LOWldm_patched/contrib/external_clip_sdxl.py3CODE
LOWldm_patched/contrib/external_upscale_model.py3CODE
LOWldm_patched/contrib/external_model_downscale.py3CODE
LOWldm_patched/contrib/external_compositing.py3CODE
LOWldm_patched/pfn/architecture/block.py4CODE
LOWldm_patched/pfn/architecture/LaMa.py10CODE
LOWldm_patched/pfn/architecture/OmniSR/OSA.py15CODE
LOWldm_patched/pfn/architecture/face/upfirdn2d.py5CODE
LOWldm_patched/ldm/models/autoencoder.py3CODE
LOWldm_patched/ldm/models/autoencoder.py5CODE
LOWldm_patched/ldm/models/autoencoder.py5CODE
LOWldm_patched/ldm/modules/attention.py6CODE
LOWldm_patched/ldm/modules/temporal_ae.py2CODE
LOWldm_patched/ldm/modules/diffusionmodules/util.py11CODE
LOWldm_patched/ldm/modules/diffusionmodules/upscaling.py7CODE
LOWldm_patched/ldm/modules/diffusionmodules/model.py6CODE
LOWldm_patched/ldm/modules/diffusionmodules/model.py7CODE
LOWldm_patched/ldm/modules/diffusionmodules/model.py7CODE
LOWldm_patched/modules/supported_models_base.py1CODE
LOWldm_patched/modules/sd2_clip.py2CODE
LOWldm_patched/modules/sample.py6CODE
LOWldm_patched/modules/model_management.py49CODE
LOWmodules/sample_hijack.py5CODE
LOWmodules/core.py19CODE
LOWmodules/gradio_hijack.py3CODE
LOWextras/BLIP/models/blip_vqa.py7CODE
LOWextras/BLIP/models/med.py12CODE
LOWextras/BLIP/models/med.py13CODE
LOWextras/BLIP/models/med.py14CODE
LOWextras/BLIP/models/med.py15CODE
LOWextras/BLIP/models/med.py22CODE
LOWextras/BLIP/models/med.py25CODE
LOWextras/BLIP/models/med.py28CODE
LOWextras/BLIP/models/med.py28CODE
LOWextras/BLIP/models/med.py28CODE
LOWextras/BLIP/models/med.py28CODE
LOWextras/BLIP/models/med.py28CODE
LOWextras/BLIP/models/med.py28CODE
LOWextras/BLIP/models/blip.py17CODE
LOWextras/BLIP/models/nlvr_encoder.py2CODE
LOWextras/BLIP/models/nlvr_encoder.py3CODE
LOWextras/BLIP/models/nlvr_encoder.py4CODE
LOWextras/BLIP/models/nlvr_encoder.py5CODE
LOWextras/BLIP/models/nlvr_encoder.py11CODE
LOWextras/BLIP/models/nlvr_encoder.py12CODE
LOWextras/BLIP/models/nlvr_encoder.py15CODE
LOWextras/BLIP/models/nlvr_encoder.py18CODE
LOWextras/BLIP/models/nlvr_encoder.py18CODE
LOWextras/BLIP/models/nlvr_encoder.py18CODE
LOWextras/BLIP/models/nlvr_encoder.py18CODE
20 more matches not shown…
Empty Error Handlers12 hits · 60 pts
SeverityFileLineSnippetContext
HIGHwebui.py605except ValueError:CODE
HIGHldm_patched/pfn/architecture/face/codeformer.py623except:CODE
HIGHldm_patched/ldm/modules/attention.py282except:CODE
HIGHldm_patched/modules/sd1_clip.py240except:CODE
HIGHldm_patched/modules/controlnet.py291except:CODE
HIGHldm_patched/modules/model_management.py52except:CODE
HIGHldm_patched/modules/model_management.py59except:CODE
HIGHldm_patched/modules/model_management.py186except:CODE
HIGHldm_patched/modules/model_management.py145except:CODE
HIGHldm_patched/modules/model_management.py156except:CODE
HIGHldm_patched/modules/model_management.py465except: #Old pytorch doesn't have .itemsizeCODE
HIGHmodules/meta_parser.py422except ValueError | KeyError:CODE
Over-Commented Block59 hits · 46 pts
SeverityFileLineSnippetContext
LOWldm_patched/pfn/architecture/OmniSR/layernorm.py1#!/usr/bin/env python3COMMENT
LOWldm_patched/pfn/architecture/OmniSR/OmniSR.py1#!/usr/bin/env python3COMMENT
LOWldm_patched/pfn/architecture/OmniSR/pixelshuffle.py1#!/usr/bin/env python3COMMENT
LOWldm_patched/pfn/architecture/OmniSR/esa.py1#!/usr/bin/env python3COMMENT
LOWldm_patched/pfn/architecture/OmniSR/OSAG.py1#!/usr/bin/env python3COMMENT
LOWldm_patched/pfn/architecture/OmniSR/OSA.py1#!/usr/bin/env python3COMMENT
LOWldm_patched/pfn/architecture/face/restoreformer_arch.py61 min_encodings = torch.zeros(min_encoding_indices.shape[0], self.n_e).to(z)COMMENT
LOWjavascript/imageviewer.js201 modalZoom.innerHTML = '⤡';COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29601collarboneCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29621##)COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29641##{COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29661##¶COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29681##ɕCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29701##ʌCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29721##βCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29741##бCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29761##іCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29781##պCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29801##םCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29821##حCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29841##چCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29861##थCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29881##।COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29901##দCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29921##டCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29941##යCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29961##་COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt29981##თCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30001##ᄌCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30021##ᆨCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30041##ᵖCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30061##„COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30081##ⁿCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30101##₤COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30121##∂COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30141##⊗COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30161##⽥COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30181##けCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30201##ふCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30221##ィCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30241##トCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30261##レCOMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30281##井COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30301##出COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30321##同COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30341##奈COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30361##崎COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30381##成COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30401##朝COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30421##氵COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30441##発COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30461##糹COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30481##車COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30501##雄COMMENT
LOWextras/BLIP/models/bert_tokenizer/vocab.txt30521##?COMMENT
LOWextras/facexlib/detection/retinaface.py361 # self.t['forward_pass'].toc(average=True)COMMENT
LOWextras/facexlib/detection/matlab_cp2tform.py241COMMENT
LOWextras/facexlib/detection/matlab_cp2tform.py261 # xy_m =COMMENT
LOWextras/safety_checker/models/safety_checker.py1# from https://github.com/huggingface/diffusers/blob/main/src/diffusers/pipelines/stable_diffusion/safety_checker.pyCOMMENT
Excessive Try-Catch Wrapping34 hits · 40 pts
SeverityFileLineSnippetContext
LOWentry_with_update.py41except Exception as e:CODE
LOWldm_patched/contrib/external.py1891 except Exception as e:CODE
LOWldm_patched/modules/sd1_clip.py330 except Exception as e:CODE
LOWldm_patched/modules/model_patcher.py252 except Exception as e:CODE
LOWldm_patched/modules/model_patcher.py291 except Exception as e:CODE
LOWldm_patched/modules/model_patcher.py320 except Exception as e:CODE
LOWldm_patched/modules/model_management.py301 except Exception as e:CODE
LOWmodules/patch.py90 except Exception as e:CODE
LOWmodules/patch.py139 except Exception as e:CODE
LOWmodules/patch.py168 except Exception as e:CODE
LOWmodules/patch.py466 except Exception as e:CODE
LOWmodules/auth.py27 except Exception as e:CODE
LOW⚡modules/config.py34except Exception as e:CODE
LOW⚡modules/config.py43except Exception as e:CODE
LOWmodules/config.py93 except Exception as e:CODE
LOWmodules/config.py125 except Exception as e:CODE
LOWmodules/config.py247 except Exception as e:CODE
LOWmodules/style_sorter.py26 except Exception as e:CODE
LOWmodules/style_sorter.py43 except Exception as e:CODE
LOWmodules/util.py229 except Exception:CODE
MEDIUMmodules/util.py253 print(f"Error: {e}")CODE
LOWmodules/util.py514 except Exception as e:CODE
LOWmodules/meta_parser.py403 except Exception:CODE
MEDIUMmodules/meta_parser.py404 print(f"Error parsing \"{k}: {v}\"")CODE
LOWmodules/sdxl_styles.py46 except Exception as e:CODE
LOWmodules/hash_cache.py38 except Exception as e:CODE
LOWmodules/hash_cache.py57 except Exception as e:CODE
LOWmodules/localization.py22 except Exception as e:CODE
LOWmodules/launch_util.py72 except Exception as e:CODE
LOW⚡modules/launch_util.py96 except Exception as e:CODE
MEDIUM⚡modules/launch_util.py97 print(f"Error checking version for {package}: {e}")CODE
LOWmodules/launch_util.py113 except Exception as e:CODE
MEDIUMmodules/launch_util.py26def is_installed(package):CODE
LOWmodules/async_worker.py213 except Exception as e:CODE
AI Slop Vocabulary9 hits · 27 pts
SeverityFileLineSnippetContext
MEDIUM⚡models/prompt_expansion/fooocus_expansion/vocab.json1{"!":0,"\"":1,"#":2,"$":3,"%":4,"&":5,"'":6,"(":7,")":8,"*":9,"+":10,",":11,"-":12,".":13,"/":14,"0":15,"1":16,"2":17,"3CODE
MEDIUM⚡models/prompt_expansion/fooocus_expansion/vocab.json1{"!":0,"\"":1,"#":2,"$":3,"%":4,"&":5,"'":6,"(":7,")":8,"*":9,"+":10,",":11,"-":12,".":13,"/":14,"0":15,"1":16,"2":17,"3CODE
MEDIUMldm_patched/contrib/external.py346 #grow mask by a few pixels to keep things seamless in latent spaceCOMMENT
MEDIUM⚡extras/BLIP/models/bert_tokenizer/tokenizer.json1{"version":"1.0","truncation":null,"padding":null,"added_tokens":[{"id":0,"special":true,"content":"[PAD]","single_word"CODE
MEDIUM⚡extras/BLIP/models/bert_tokenizer/tokenizer.json1{"version":"1.0","truncation":null,"padding":null,"added_tokens":[{"id":0,"special":true,"content":"[PAD]","single_word"CODE
MEDIUM⚡extras/BLIP/models/bert_tokenizer/tokenizer.json1{"version":"1.0","truncation":null,"padding":null,"added_tokens":[{"id":0,"special":true,"content":"[PAD]","single_word"CODE
MEDIUM⚡extras/BLIP/models/bert_tokenizer/tokenizer.json1{"version":"1.0","truncation":null,"padding":null,"added_tokens":[{"id":0,"special":true,"content":"[PAD]","single_word"CODE
MEDIUM⚡extras/BLIP/models/bert_tokenizer/tokenizer.json1{"version":"1.0","truncation":null,"padding":null,"added_tokens":[{"id":0,"special":true,"content":"[PAD]","single_word"CODE
MEDIUM⚡extras/BLIP/models/bert_tokenizer/tokenizer.json1{"version":"1.0","truncation":null,"padding":null,"added_tokens":[{"id":0,"special":true,"content":"[PAD]","single_word"CODE
Decorative Section Separators7 hits · 21 pts
SeverityFileLineSnippetContext
MEDIUMldm_patched/pfn/architecture/Swin2SR.py2# -----------------------------------------------------------------------------------COMMENT
MEDIUMldm_patched/pfn/architecture/Swin2SR.py6# -----------------------------------------------------------------------------------COMMENT
MEDIUMldm_patched/pfn/architecture/SwinIR.py2# -----------------------------------------------------------------------------------COMMENT
MEDIUMldm_patched/pfn/architecture/SwinIR.py5# -----------------------------------------------------------------------------------COMMENT
MEDIUMldm_patched/pfn/architecture/SCUNet.py2# -----------------------------------------------------------------------------------COMMENT
MEDIUMldm_patched/pfn/architecture/SCUNet.py5# -----------------------------------------------------------------------------------COMMENT
MEDIUMldm_patched/pfn/architecture/face/codeformer.py761 # ------------COMMENT
Hallucination Indicators2 hits · 20 pts
SeverityFileLineSnippetContext
CRITICALmodules/patch.py340 t_emb = ldm_patched.ldm.modules.diffusionmodules.openaimodel.timestep_embedding(timesteps, self.model_channels, repeCODE
CRITICALmodules/patch.py394 t_emb = ldm_patched.ldm.modules.diffusionmodules.openaimodel.timestep_embedding(timesteps, self.model_channels, repeCODE
Modern AI Meta-Vocabulary1 hit · 3 pts
SeverityFileLineSnippetContext
MEDIUM⚡models/prompt_expansion/fooocus_expansion/vocab.json1{"!":0,"\"":1,"#":2,"$":3,"%":4,"&":5,"'":6,"(":7,")":8,"*":9,"+":10,",":11,"-":12,".":13,"/":14,"0":15,"1":16,"2":17,"3CODE
Cross-Language Confusion1 hit · 2 pts
SeverityFileLineSnippetContext
HIGHmodules/private_logger.py73 if (navigator.clipboard && navigator.permissions) {STRING
Redundant / Tautological Comments1 hit · 2 pts
SeverityFileLineSnippetContext
LOW⚡modules/launch_util.py92 # Check if the installed version satisfies the requirementCOMMENT
Slop Phrases1 hit · 1 pts
SeverityFileLineSnippetContext
LOW.github/ISSUE_TEMPLATE/bug_report.yml32 > Please fill this form with as much information as possible. Don't forget to add information about "What browseCODE
Modern Structural Boilerplate1 hit · 1 pts
SeverityFileLineSnippetContext
LOWextras/facexlib/utils/__init__.py4__all__ = [CODE