MCPcopy Index your code
hub / github.com/huggingface/diffusers / main

Function main

src/diffusers/commands/diffusers_cli.py:23–41  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

21
22
23def main():
24 parser = ArgumentParser("Diffusers CLI tool", usage="diffusers-cli <command> [<args>]")
25 commands_parser = parser.add_subparsers(help="diffusers-cli command helpers")
26
27 # Register commands
28 EnvironmentCommand.register_subcommand(commands_parser)
29 FP16SafetensorsCommand.register_subcommand(commands_parser)
30 CustomBlocksCommand.register_subcommand(commands_parser)
31
32 # Let's go
33 args = parser.parse_args()
34
35 if not hasattr(args, "func"):
36 parser.print_help()
37 exit(1)
38
39 # Run
40 service = args.func(args)
41 service.run()
42
43
44if __name__ == "__main__":

Callers 1

diffusers_cli.pyFile · 0.70

Calls 2

register_subcommandMethod · 0.45
runMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…