Home Page >  News List >> Tech >> Tech

Running StableDiffusion with just one click on a Mac

Tech 2023-07-17 10:51:49 Source: Network
AD

StableDiffusion is different from the client software we usually use. It requires entering instructions at the terminal each time it runs, and then opening the browser to input the website address

StableDiffusion is different from the client software we usually use. It requires entering instructions at the terminal each time it runs, and then opening the browser to input the website address. The operation is quite cumbersome. We can use the shortcut instruction tool provided by the Mac computer to run it with one click, and the script part of this instruction is written with ChatGPT assistance.

Operating Steps

Open the shortcut command app, locate the action 'Run AppleScript', and drag it into the left editing panel


Copy the following code to replace the default code. The purpose of these codes is to start Terminal and enter the necessary instructions to start SD. After replacing, I see a purple color with no formatting in the text. Don't panic, it's not your problem. Keep moving forward

Onrun {input, parameters} tellapplicationTerminalToactivate # Open terminaltellapplicationSystemEventsTokystrokeCD/Users/Bavoch/table differentiation webuiDelayoneTellapplicationSystemEventsTokystrokeReturnTellapplicationSystemEventsTokystroke./webui. shDelayoneTellapplicationSystemEventsTokystrokeReturnend run

Click on the "Hammer" icon to compile. The first run may prompt for permission issues. Go to "Settings Privacy and Security Auxiliary Functions", turn on the "Siriationsd" switch, and then try again. It should be no problem.

If everything is normal, the code will be formatted as shown in the following image, which is much more comfortable.

Find the 'Open URL' action and add it to the editing panel

Click on the blue text 'AppleScript Results' and click' Clear 'in the pop-up window

http://one27.0.0.one:7860

This completes the creation of this shortcut command. You can now click the "Play" button in the upper right corner to run it and see if it is successful.

Tip: When the running address is first opened, it will prompt "Unable to access this website" because the terminal command has not been completed yet. Wait a moment, and it will be ready.

Finally, let's do some finishing work and give your shortcut commands an easily recognizable name with a nice icon. For ease of use, we checked "Fixed in Menu Bar" in the right property panel and set a shortcut key (the other checks were checked by the system when I set the shortcut key, which felt like a bug, regardless of it)

This way, every time you click on the shortcut command menu in the menu bar or use the set shortcut keys in the future, you can run SD.


Disclaimer: The content of this article is sourced from the internet. The copyright of the text, images, and other materials belongs to the original author. The platform reprints the materials for the purpose of conveying more information. The content of the article is for reference and learning only, and should not be used for commercial purposes. If it infringes on your legitimate rights and interests, please contact us promptly and we will handle it as soon as possible! We respect copyright and are committed to protecting it. Thank you for sharing.(Email:[email protected])

Mobile advertising space rental

Tag: Running StableDiffusion with just one click on Mac

Unite directoryCopyright @ 2011-2024 All Rights Reserved. Copyright Webmaster Search Directory System