Commit Graph

96 Commits (main)

Author SHA1 Message Date
SpenserCai 945e00bfc3
Merge pull request #63 from SpenserCai/dev
Dev
2024-03-20 14:56:21 +08:00
SpenserCai fad43553bf
Merge pull request #56 from light-and-ray/main
improve webui extension
2024-03-20 14:54:58 +08:00
SpenserCai a2090cab77
Merge pull request #59 from ranareehanaslam/patch-1
Optimize DeOldify setup script
2024-03-20 14:52:32 +08:00
SpenserCai eadda8f65d
Merge pull request #62 from SpenserCai/dev
Merge pull request #61 from SpenserCai/main
2024-03-20 14:49:58 +08:00
SpenserCai dae46ff24b
Merge pull request #61 from SpenserCai/main
update
2024-03-20 14:49:38 +08:00
SpenserCai 418712cb2e
Merge pull request #60 from light-and-ray/fix_logger
fix logger level
2024-03-20 14:48:12 +08:00
Andray a51ed9ebe4 fix logger level 2024-03-11 19:28:12 +04:00
Muhammad Rehan Aslam eacf3df775
Optimize DeOldify setup script
Optimize DeOldify setup script for efficiency and user feedback This …
…commit introduces several optimizations and enhancements to the DeOldify setup script, focusing on improving efficiency, user feedback, and error handling. Key changes include the implementation of an immediate check to avoid re-downloading already existing models, the use of tqdm for enhanced download progress reporting, streamlined dependency checking and installation, and consolidated feedback messages for already downloaded models and satisfied dependencies. These improvements aim to enhance the script's performance, reduce unnecessary operations, and provide clearer, more concise feedback to users.

### Summary of Changes

1. **Directory Creation Optimization**:
   - Utilized `os.makedirs(models_dir, exist_ok=True)` to ensure the creation of the models directory if it does not exist, with `exist_ok=True` to avoid raising an error if the directory already exists. This change optimizes the directory creation step by making it more concise and efficient.

2. **Download Function Enhancement**:
   - Added a check at the beginning of the `download` function to immediately return `False` if the file already exists, thus avoiding unnecessary download attempts and network traffic. This optimization ensures that the script does not attempt to re-download models that have already been downloaded, saving time and resources.

3. **Download Progress Reporting**:
   - Implemented the use of `tqdm` in the `download` function for better progress reporting. This enhancement provides a visual progress bar during model downloads, offering real-time feedback on download progress and improving the user experience.

4. **Simplified Dependency Checking**:
   - The `check_and_install_dependencies` function was refined to iterate through the list of dependencies and check if each is installed, and if not, to install it. This process is streamlined by splitting each dependency into its name and version (if specified), simplifying the handling of version-specific dependencies.

5. **Consolidated Feedback for Dependencies and Models**:
   - Modified both the `download_models` and `check_and_install_dependencies` functions to provide consolidated feedback. If all models are already downloaded or if all dependencies meet the version requirements, a single message is printed, reducing output clutter. This change enhances the script's usability by providing clear and concise feedback about the status of models and dependencies.

6. **Error Handling in Download Function**:
   - Improved error handling in the `download` function to catch exceptions and print a failure message, aiding in troubleshooting and enhancing the robustness of the model download process.

### Commit Message for Pull Request

```
Optimize DeOldify setup script for efficiency and user feedback

This commit introduces several optimizations and enhancements to the DeOldify setup script, focusing on improving efficiency, user feedback, and error handling. Key changes include the implementation of an immediate check to avoid re-downloading already existing models, the use of tqdm for enhanced download progress reporting, streamlined dependency checking and installation, and consolidated feedback messages for already downloaded models and satisfied dependencies. These improvements aim to enhance the script's performance, reduce unnecessary operations, and provide clearer, more concise feedback to users.
```
2024-03-01 17:11:58 +05:00
Andray 9d61de570f
Update README.md: remove --disable-safe-unpickle 2024-02-08 19:52:15 +04:00
Andray 9b475f5205 improve webui extension 2024-02-08 19:44:32 +04:00
SpenserCai 13c6d11797
Merge pull request #53 from SpenserCai/dev
Merge pull request #52 from SpenserCai/main
2024-01-30 10:16:03 +08:00
SpenserCai 54f0f4d300
Merge pull request #52 from SpenserCai/main
merge
2024-01-30 10:15:44 +08:00
SpenserCai 4ecf79c00f
Merge pull request #51 from light-and-ray/main
Add input accordion
2024-01-30 10:13:55 +08:00
Andray 6a77f15a9c Add input accorion 2024-01-23 03:20:56 +04:00
SpenserCai 49380c1051
Merge pull request #34 from SpenserCai/dev
Support sd-webui 1.6.0 add,Pre-Pre-Decolorization
2023-09-07 10:55:08 +08:00
SpenserCai 88fb3faaac test finish 2023-09-07 10:51:28 +08:00
SpenserCai d13d588ada test 2023-09-07 10:46:14 +08:00
SpenserCai 6b1c4f5bb0 support Pre-Decolorization option 2023-09-07 10:34:04 +08:00
SpenserCai 2fabd0ee96
Merge pull request #31 from SpenserCai/dev
update readme
2023-08-28 01:06:32 +08:00
SpenserCai 9e31281b3a update readme 2023-08-28 01:06:02 +08:00
SpenserCai ce52b233a9
Merge pull request #29 from SpenserCai/dev
Add Progress Bar
2023-08-21 17:37:30 +08:00
SpenserCai 2c23ad1c01 add copying status 2023-08-21 17:29:41 +08:00
SpenserCai 1c6d45e315 add Extracting status 2023-08-21 17:22:49 +08:00
SpenserCai 937ac3567e add progress bar 2023-08-21 17:15:24 +08:00
SpenserCai 3cd19062dc
Merge pull request #26 from SpenserCai/dev
update:sd-webui-go's version
2023-08-15 21:06:03 +08:00
SpenserCai a484066d8b update:sd-webui-go's version 2023-08-15 21:05:01 +08:00
SpenserCai 609172df4c
Merge pull request #25 from SpenserCai/dev
Dev
2023-08-13 12:59:56 +08:00
SpenserCai a88d2b8533 update go package 2023-08-13 12:55:10 +08:00
SpenserCai 49b498eb4f update mod 2023-08-13 12:40:37 +08:00
SpenserCai b6f346fefc
Merge pull request #24 from SpenserCai/dev
update readme
2023-08-13 01:14:18 +08:00
SpenserCai 929fb28bd2 update readme 2023-08-13 01:12:17 +08:00
SpenserCai 43f2b34d7b
Merge pull request #23 from SpenserCai/dev
open source discord bot
2023-08-12 22:06:20 +08:00
SpenserCai 505655bcd2 open source discord bot 2023-08-12 22:05:29 +08:00
SpenserCai c36578dd2c
Merge pull request #22 from SpenserCai/dev
Merge pull request #21 from SpenserCai/main
2023-08-12 02:29:39 +08:00
SpenserCai 8eafd92ba3
Merge pull request #21 from SpenserCai/main
update commit history
2023-08-12 02:28:41 +08:00
SpenserCai 819e26f93e
Merge pull request #20 from SpenserCai/dev
update gif
2023-08-12 02:26:51 +08:00
SpenserCai 1b7dae4f85 update gif 2023-08-11 01:43:38 +08:00
SpenserCai bf5cb711d5
Merge pull request #19 from SpenserCai/dev
the deoldifybot online
2023-08-11 01:34:45 +08:00
SpenserCai 272322a268 the deoldifybot online 2023-08-11 01:34:01 +08:00
SpenserCai 529bffbf88
Merge pull request #18 from SpenserCai/dev
api tested and support url
2023-08-09 22:38:16 +08:00
SpenserCai 6a4a889416 fix_bug 2023-08-09 22:32:00 +08:00
SpenserCai a802a24506 api support url 2023-08-09 22:25:54 +08:00
SpenserCai d9b25957fc
Merge pull request #17 from SpenserCai/dev
code optimization
2023-08-09 10:36:33 +08:00
SpenserCai ac2ff10a92 Code optimization 2023-08-09 10:11:50 +08:00
SpenserCai b6f793cc2b fxi bug 2023-08-09 10:06:11 +08:00
SpenserCai 013ef48ddb code optimize 2023-08-09 10:02:50 +08:00
SpenserCai 38a9176e45
Merge pull request #16 from SpenserCai/dev
add logo
2023-08-08 23:26:54 +08:00
SpenserCai a7b9f7c009 add logo 2023-08-08 23:25:45 +08:00
SpenserCai 543f7ae8dd
Merge pull request #15 from SpenserCai/dev
add discord
2023-08-08 17:59:27 +08:00
SpenserCai d84b37eb87 add discord 2023-08-08 17:58:28 +08:00