Giter Site home page Giter Site logo

zanllp / sd-webui-infinite-image-browsing Goto Github PK

View Code? Open in Web Editor NEW
920.0 7.0 116.0 23.89 MB

A fast and powerful image/video browser for Stable Diffusion webui / ComfyUI / Fooocus / NovelAI / StableSwarmUI, featuring infinite scrolling and advanced search capabilities using image parameters. It also supports standalone operation.

License: MIT License

Python 27.87% JavaScript 2.51% HTML 0.15% Vue 30.40% TypeScript 36.98% SCSS 1.27% CSS 0.01% Rust 0.81%
stable-diffusion-webui stable-diffusion-webui-plugin previewer image-previewer file-explorer extension gallery comfyui video video-player

sd-webui-infinite-image-browsing's Introduction

🌍 i18n Advisory: Some translations may be incomplete or inaccurate. Pull requests are welcome for improvements!

🌐 Try our application online at: http://39.105.110.128:0721. This is my idle 2c2g3m cloud server without CDN.

中文文档 Change log Installation / Running

Stable Diffusion webui Infinite Image Browsing

It's not just an image/video browser, but also a powerful image manager. Precise image search combined with multi-selection operations allows for filtering/archiving/packaging ...etc, greatly increasing efficiency. It also supports running in standalone mode, without the need for SD-Webui.

It is also suitable for managing regular photos and videos, allowing you to tag or search them. We have made numerous optimizations to ensure performance under extreme conditions.

20230621_230736.mp4

Software Support and Development Progress Overview

Software Support Provided by
Stable Diffusion web UI Supported Built-in
ComfyUI Partially supported Built-in
Fooocus Supported Built-in
NovelAI Supported Built-in
StableSwarmUI Supported Built-in
Pixiv Supported pixiv_iib_plugin

You can add your own parser through parsers, You can also implement parsing for more formats by writing plugins. For reference, see pixiv_iib_plugin

Key Features

🔥 Excellent Performance

  • Once caching is generated, images can be displayed in just a few milliseconds.
  • Images are displayed with thumbnails by default, with a default size of 512 pixels. You can adjust the thumbnail resolution on the global settings page.
  • You can also control the width of the grid images, allowing them to be displayed in widths ranging from 64px to 1024px.
  • Supports pre-generating thumbnails and video covers to improve performance using --generate_video_cover and --generate_image_cache.
  • Supports specifying the cache directory through the IIB_CACHE_DIR environment variable.

🔍 Image Search & Favorite

  • The prompt, model, Lora, and other information will be converted into tags and sorted by frequency of use for precise searching.
  • Supports tag autocomplete, auto-translation, and customization.
  • Image favorite can be achieved by toggling custom tags for images in the right-click menu.
  • Support for advanced search similar to Google
  • Also supports fuzzy search, you can search by a part of the filename or generated information.
  • Support adding custom search paths for easy management of folders created by the user.

🖼️ View Images/Videos & Send To

  • Supports viewing image generation information. Also supported in full-screen preview mode.
  • Supports sending images to other tabs and third-party extensions such as ControlNet , openOutpaint.
  • Support full-screen preview and enable custom shortcut key operations while in full-screen preview mode.
  • Support navigating to the previous or next image in full-screen preview mode by pressing arrow keys or clicking buttons.
  • Support playing video files from a remote server.

💻 Multiple Usage Methods

  • You can install it as an extension on SD-webui.
  • You can run it independently using Python.
  • The desktop app version is also available.
  • Supports multiple popular AI software.

🚶‍♀️ Walk Mode

  • Automatically load the next folder (similar to os.walk), allowing you to browse all images without paging.
  • Tested to work properly with over 27,000 files.
  • When there are folders, you can switch to walk mode from other modes by clicking the walk button in the upper right corner. It will flatten all the folders, avoiding the tedious operation of going in and out of folders.

🌳 Preview based on File Tree Structure & File operations

  • Supports file tree-based preview.
  • Supports automatic refreshing.
  • Supports basic file operations, such as multiple selection for deleting/moving/copying, and creating new folders.
  • Hold down the Ctrl, Shift, or Cmd key to select multiple items.
    • Supported multi-select operations include: delete, move, copy, pack download, add tags, remove tags, move to another folder, copy to another folder, drag and drop.
    • You can keep the multi-select state by clicking the "Keep Multi-Select" button in the lower right corner, allowing you to perform multiple operations on the selected file collection conveniently.

🆚 image comparison (similar to Imgsli)

  • Provides a side-by-side comparison of two images.
  • Provides a comparison of image generation information at the same time.

🌐 Multilingual Support

  • Currently supports Simplified Chinese/Traditional Chinese/English/German.
  • If you would like to add a new language, please refer to i18n.ts and submit the relevant code.

🔐 Privacy and Security

  • Supports custom secret key for authentication.
  • Supports configuring access control for the file system, which will be enabled by default when the service allows public access (Only when used as an extension of sd-webui).
  • Supports customizing the allowed paths for access control.
  • Supports controlling access permissions. You can run IIB in read-only mode.
  • Click here to see details

📦 Packaging/Batch Download

  • Allows you to download multiple images at once.
  • The data source can be search results, a regular image grid view page, walk mode, etc. Images can be added to the processing list through drag-and-drop or "Send To".

⌨️ Keyboard Shortcuts

  • Allows for deleting and adding/removing tags, with customizable trigger buttons in the global settings page.

If you like this project and find it helpful, please consider giving it a ⭐️. This would be very important for me to continue developing and maintaining this project. If you have any suggestions or ideas, please feel free to raise them in the issue section, and I will respond as soon as possible. Thank you again for your support!

Buy Me a Coffee at ko-fi.com

Sponsor me on WeChat

Installation / Running

As an extension for SD-webui:

  1. Open the Extensions tab in SD-webui.
  2. Select the Install from URL option.
  3. Enter https://github.com/zanllp/sd-webui-infinite-image-browsing.
  4. Click on the Install button.
  5. Wait for the installation to complete and click on Apply and restart UI.

As a standalone program that runs using Python. (without SD-webui):

Refer to Can the extension function without the web UI?

If you need to view images generated by ComfyUI/Fooocus/NovelAI, please refer to https://github.com/zanllp/sd-webui-infinite-image-browsing/issues/202.

If you need a Dockerfile, you can refer to this link. #366

As a desktop application (without SD-webui and Python):

The executable version also supports ComfyUI/Fooocus/NovelAI.

Download and install the program from the releases section on the right-hand side of the repository page. If the antivirus detects a virus, it can be ignored as a false positive.

If you need to compile it yourself, please refer to https://github.com/zanllp/sd-webui-infinite-image-browsing/blob/main/.github/workflows/tauri_app_build.yml.

As a Library Usage:

Use iframe to access IIB and use it as a file browser for your application. Refer to https://github.com/zanllp/sd-webui-infinite-image-browsing/blob/main/vue/usage.md

Preview

image

Image Search

During the first use, you need to click and wait for the index generation. For my case with 20,000 images, it took about 15 seconds (with an AMD 5600X CPU and PCIe SSD). For subsequent uses, it will check whether there are changes in the folder, and if so, it needs to regenerate the index. Usually, this process is very fast.

Image search supports translation, see #39 for more detail. Feel free to share files for other languages to facilitate everyone's use. image image

Full Screen Preview (Side-by-Side Layout)

11

Full Screen Preview

image

In full-screen preview mode, you can also view image information and perform operations on the context menu. It supports dragging, resizing and expanding/collapsing .

20230430_070858.mp4

If you, like me, don't need to view the generation information, you can choose to simply minimize this panel, and all contextual operations will still be available.

image

Image comparison

ezgif com-video-to-gif

Transfer files between different tab panes.

20231221_212010.mp4

Right-click menu

image

You can also trigger it by hovering your mouse over the icon in the top right corner.

image

Walk mode

20230409_183837.mp4

Dark mode

image

sd-webui-infinite-image-browsing's People

Contributors

alulkesh avatar chubbly avatar cobryan05 avatar coreyryanhanson avatar cy745 avatar koaqiu avatar kominostyle avatar lcolok avatar rayadaschn avatar wfjsw avatar wsh032 avatar zanllp avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

sd-webui-infinite-image-browsing's Issues

无法发送到保存的文件夹

显示 No such file or directory: 'E:/sd-webui-aki-v4/extensions/sd-webui-infinite-image-browsing/log/images'
好像也没有设置这个文件夹的选项

Not comfortable with upload functionality

At a first glance, this looks great. But it - assuming I have correctly read the code (I haven't run it because of the below:)

  1. Autodownloads "BaiduPCS-Go", which is a library (?) I can find little-to-no English-language references to, from either github (sure) or a random HTTP .cn domain, with no signing (!!). An adversary could easily fail the github download and then respond with whatever they wished for the second download.
  2. Ditto, I have little-to-no method of verifying that BaiduPCS-Go, even when properly installed, isn't doing anything nefarious. It is a large library in a language I don't speak, that intrinsically has network functionality, from - assuming "Baidu" is in fact the same company - a company that has been caught doing nefarious things in the past.
  3. Has a bunch of functionality around uploading files, including references to autouploading.
  4. Has classic parent-directory-traversal vulnerabilities in e.g. file deletion. Admittedly, said API is not safe in general, but still worth noting.

Could non-local functionality please be broken out into a separate extension?

Refresh doesn't work

When I click refresh on my output folder and it doesn't refresh, I have to close the tab, or open another and browse back to the folder, only then it's updated

No error in the console, it's been like that on multiple commits

This is the log content before using git pull.

          This is the log content before using git pull.

After using git pull, there is no log left.

2023-04-27 10:32:19,083 - scripts.logger - ERROR - [WinError 3] ������ ��θ� ã�� �� �����ϴ�: 'C:/Users/bluen/Documents/AI/stable-diffusion-webui-ux/stable-diffusion-webui-ux/outputs'
2023-04-27 10:32:22,759 - scripts.logger - ERROR - [WinError 3] ������ ��θ� ã�� �� �����ϴ�: 'C:/Users/bluen/Documents/AI/stable-diffusion-webui-ux/stable-diffusion-webui-ux/outputs'

Originally posted by @bluenyx in #52 (comment)

Errors during folder browsing

This is what is displayed in the console while navigating through folders and viewing pictures.
I see a strange presence of baidu_netdisk in the error:
API error: GET: http://127.0.0.1:7860/baidu_netdisk/file?filename=C%3A%5CSD_MY%5C21 {'error': 'RuntimeError', 'detail': '', 'body': '', 'errors': 'File at path C:\\SD_MY\\21 is not a file.'}

Or reports an error that the folder is not a file :)
RuntimeError: File at path C:\SD_MY\34_Elldreths Retro Mix is not a file.
(34_Elldreths Retro Mix - is folder name)

error

发送功能无效

图片的右键菜单中,发送到文生图/图生图/局部重绘/附加功能,点击后没有反应,信息并未发送过去。

gradio: 3.23.0
stable-diffusion-webui commit: [22bcc7be]

漏了最重要的功能,多选

图越来越多的时候,如果不能多选图,然后删除,功能是不完善的。一张张图去删除将会是灾难。

Feature request: ignore selected file types

I usually make my setup dump .txt files with prompt info and metadata along with my rendered images. So in my image folders, there will be an [image] followed by a [txt] file, then [img], [txt], etc.

When browsing my folders in Infinite Image Browser, all my TXT files are visible as well. It would be great if there was a way to tell the extension to ignore (not show) certain file types, in my case .txt files.

As an image browser, I only want it to show me the images.

Screenshot 2023-04-23 16 29 58

Feature request: Automatic Refresh

I don't know if it's possible to implement, but is it possible to add an automatic refresh (at certain intervals or whenever a new element is added to the folder) so images get shown as they are created during bigger batches of image generation.

This would of course only be useful during imagegeneration, but it would add a lot of quality of life and seems simple enough not to harm anything.
I got tired of manually clicking refresh after each creation for it to show up, as the standard web-ui doesn't let me open images in fullscreen during generation.

无法给多个选中的图像添加like收藏标签

大佬您好!

如标题所言,用shift或者ctrl选中多个图片然后右键->切换标签选中(收藏),只能给右键时鼠标所指的图片添加收藏标签。

我以为表现会和右键->删除选中一样可以作用多个图片,结果发现不符合预期,还请大佬抽空排查一下,谢谢大佬🙏

Lock access to specific folders

Any chance you could add locking access to specific folders only?
This is especially useful when sharing SD webui with other people
Otherwise they will simply be able to access almost everything on your PC

Bug: Copy source file preview link stopped working

Since the latest update that was supposed to fix the missing translation issue, the function stopped working. If I click "Copy source file preview link", it does not show any message at all. I also tried to paste to check if the link was actually copied and the message was missing, it did not paste anything either. It seems completely not functioning at the moment.

发送到保存文件夹和切换标签选中时出错

如题,例如在stable-diffusion-webui/outputs/txt2img-images/2023-05-05的文件夹下的图片,想发送到指定文件夹或指定标签时会出现以下错误:

  1. 非 Stable Diffusion webui 文件夹下不支持切换 tag,如果有需要请提 Issue
  2. 移动文件 C:\Projects\stable-diffusion-webui\outputs\txt2img-images\2023-05-05\00268-4098422362.png 到 C:/Projects/stable-diffusion-webui/extensions/sd-webui-infinite-image-browsing/log/images 时出错:[Errno 2] No such file or directory: 'C:/Projects/stable-diffusion-webui/extensions/sd-webui-infinite-image-browsing/log/images'

[问题反馈] 有的时候无法点开图片查看大图

点开某个输出文件夹后预览正常显示, 但点击其中任何图片都打不开, 控制台报错如下(此现象会随机出现):

ERROR:    Exception in ASGI application
Traceback (most recent call last):
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/uvicorn/protocols/http/h11_impl.py", line 428, in run_asgi
    result = await app(  # type: ignore[func-returns-value]
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/uvicorn/middleware/proxy_headers.py", line 78, in __call__
    return await self.app(scope, receive, send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/fastapi/applications.py", line 273, in __call__
    await super().__call__(scope, receive, send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/applications.py", line 122, in __call__
    await self.middleware_stack(scope, receive, send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/middleware/errors.py", line 184, in __call__
    raise exc
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/middleware/errors.py", line 162, in __call__
    await self.app(scope, receive, _send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/middleware/gzip.py", line 24, in __call__
    await responder(scope, receive, send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/middleware/gzip.py", line 44, in __call__
    await self.app(scope, receive, self.send_with_gzip)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 79, in __call__
    raise exc
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 68, in __call__
    await self.app(scope, receive, sender)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 21, in __call__
    raise e
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 18, in __call__
    await self.app(scope, receive, send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/routing.py", line 718, in __call__
    await route.handle(scope, receive, send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/routing.py", line 276, in handle
    await self.app(scope, receive, send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/routing.py", line 69, in app
    await response(scope, receive, send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/responses.py", line 342, in __call__
    raise RuntimeError(f"File at path {self.path} is not a file.")
RuntimeError: File at path /mnt/Data/sd-linux/outputs/txt2img-images/2023-05-02 is not a file.
ERROR:    Exception in ASGI application
Traceback (most recent call last):
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/uvicorn/protocols/http/h11_impl.py", line 428, in run_asgi
    result = await app(  # type: ignore[func-returns-value]
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/uvicorn/middleware/proxy_headers.py", line 78, in __call__
    return await self.app(scope, receive, send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/fastapi/applications.py", line 273, in __call__
    await super().__call__(scope, receive, send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/applications.py", line 122, in __call__
    await self.middleware_stack(scope, receive, send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/middleware/errors.py", line 184, in __call__
    raise exc
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/middleware/errors.py", line 162, in __call__
    await self.app(scope, receive, _send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/middleware/gzip.py", line 24, in __call__
    await responder(scope, receive, send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/middleware/gzip.py", line 44, in __call__
    await self.app(scope, receive, self.send_with_gzip)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 79, in __call__
    raise exc
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 68, in __call__
    await self.app(scope, receive, sender)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 21, in __call__
    raise e
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 18, in __call__
    await self.app(scope, receive, send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/routing.py", line 718, in __call__
    await route.handle(scope, receive, send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/routing.py", line 276, in handle
    await self.app(scope, receive, send)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/starlette/routing.py", line 66, in app
    response = await func(request)
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/fastapi/routing.py", line 237, in app
    raw_response = await run_endpoint_function(
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/fastapi/routing.py", line 163, in run_endpoint_function
    return await dependant.call(**values)
  File "/mnt/Data/sd-linux/extensions/sd-webui-infinite-image-browsing/scripts/api.py", line 313, in image_geninfo
    with Image.open(path) as img:
  File "/mnt/Data/sd-linux/venv/lib/python3.10/site-packages/PIL/Image.py", line 3227, in open
    fp = builtins.open(filename, "rb")
FileNotFoundError: [Errno 2] No such file or directory: 'undefined'

搜索功能中部分图片的tag并未被识别

首先,非常感谢加入了搜索功能。这个浏览器真的非常好用!

使用搜索功能时,部分图片的某些tag并未被识别,因此无法通过其包含的tag搜索到该图片。
我并不清楚为何某些tag没有被识别,但经过观察,我怀疑是由于以下情况引起的:

目前,对tag的识别是把逗号作为唯一的分隔符在处理的。当一个tag字符串前面不是以逗号分隔,而是以其他符号分隔时,该tag就不会被识别。例如:

有两张图片,
图片A的prompt为:
realistic, still life, flower
图片B的prompt为:
realistic. still life, flower

那么输入still life进行搜索,就只能搜到图片A,无法搜到图片B.

建议加入更完善的规则以区分tag,将. | <> () [] {} :等符号纳入其中。

P.S. 考虑到有些prompt可能是自然语言,或许换种搜索方式更好?

feature request: A tab to collect prompts from outside ?

Thanks for your plugin ! Maybe it would be nice to have an option to collect some generation data and picture directly from outside when surfing on the internet ( like civitai, lexica, etc... ) by copy/paste and a way to organize them in your plugin solution.. Just an idea !! Again thanks for this incredible addon !

Support for relative folder paths

Currently when using relative paths for output directory (such as outputs/txt2img-images,outputs/txt2img-grids etc. which are the default settings), Quick Move actions fail to work (including from "Use Walk mode to browse images" buttons) with "Move failed. Check your path input."

It tries to go to the outputs folder immediately instead of navigating to the correct drive and folder, and fails

I think it could be solved by adding the current working directory into the path first (like D:/foo/bar/stable-diffusion-webui/outputs/txt2img-images) before doing the Quick Move

You mind making an English version?

This is better than the regular image browser for Stable Diffusion. I wanted something like this for a long time, but I can't read any of it, so an English version might be better also to add

Also, when viewing the prompt and when you press OK, it doesn't close, but only the cancel button works. I don't know if it was made like this, but the OK button doesn't close the prompt viewing.

Sent to XXX sends all the settings as prompt

When selecting and image, then send it to txt2img for instance from the context menu, all the settings are sent as a prompt, so now the prompt containts model hash, cfg, seed etc

Feature request: Add favorite system to save images

Hey ! I noticed you have a folder under /log to save images. Could you add a "Add to favorites" button, either in the the contextual menu you get on an image or perhaps a button overlay when you hover over an image, that'll add any selected images to that folder or maybe a custom one ? This would be a great function.

Also and unrelated, could you increase the opacity of the dark background that appears on viewer mode? Right now it's a bit hard to see it's a new window on top of the UI.

Thanks :)

Feature request: simplify the start page

Launch from Quick Move in the start page looks overcomplicated with items that are never used. For example, I see the following items in my start page.

    Text to image
    Image to image
    Directory for saving images using the Save button
    Extra
    Image to image grid
    Text to image grid
    hypernetworks
    Embedding
    Working folder
    home

There are too many items!

  1. Browsing image grids is sort of useless because this extension does better job at viewing lots of images. They can be removed.
  2. I don't even know why there are the model directories such as hypbernetwork and Embedding are here. Those are not image directories. They can be removed.
  3. working folder and home are not frequently unless the extension is used as a generic image browser. They can be removed?
  4. wordings are inconsistent with the terms used in Stable Diffusion Web UI.

TLDR I think the list can be simplified like this.

   txt2img
   img2img
   extra
   save

刷新功能并不总是有用

查看文生图文件夹下的图片,然后到文生图生成一张图片,再回到图片浏览器,点击右上角的刷新没有反应,大概率需要重新打开一个标签,或者跳转到其他文件夹再跳转回来才行。

还有一个稳定的bug,重载前端后出错,打开任意硬盘提示 “ [WinError 123] 文件名、目录名或卷标语法不正确。: '/E:/' “此时包括搜索、最近记录等功能都不可使用,不过只要刷新一下页面功能就恢复正常。(非专业人士提供一个薄见,可能是页面重载某些地址变量刷新,但插件对地址的操作没有刷新?)

Feature request, Select multiple images

Can you add Select multiple images at once?

It will be useful for cleaning up and deleting many images in one time. as of now I have to right click and delte one by one ;-(

Feature Request: Image Search Inclusive Filtering

When searching for an image using Image Search, the search matches only all tags exclusively.

It would be fantastic if I could use the search to find all images matching the prompt "landscape" but have used different samplers, e.g., "[pos]landscape [sampler]Euler OR [sampler] Euler a". Current, if I select more than 1 sampler to search with, it will return zero images because no image has been generated using 2 samplers.

I hope this feature wouldn't be too difficult to implement, it would make the search function incredibly useful for doing comparisons between different models and samplers.

Thank you!

DB error (Image search)

image

Error when pressing Image Search. No logs were left, so it's not clear what the error was. After the first time it works, it happens when you click Reload UI. After that, it doesn't work.

ERROR: Exception in ASGI application
Traceback (most recent call last):
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\uvicorn\protocols\http\h11_impl.py", line 429, in run_asgi
result = await app( # type: ignore[func-returns-value]
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\uvicorn\middleware\proxy_headers.py", line 78, in call
return await self.app(scope, receive, send)
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\fastapi\applications.py", line 273, in call
await super().call(scope, receive, send)
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\starlette\applications.py", line 122, in call
await self.middleware_stack(scope, receive, send)
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\errors.py", line 184, in call
raise exc
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\errors.py", line 162, in call
await self.app(scope, receive, _send)
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\gzip.py", line 24, in call
await responder(scope, receive, send)
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\gzip.py", line 44, in call
await self.app(scope, receive, self.send_with_gzip)
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\exceptions.py", line 79, in call
raise exc
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\exceptions.py", line 68, in call
await self.app(scope, receive, sender)
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 21, in call
raise e
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 18, in call
await self.app(scope, receive, send)
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\starlette\routing.py", line 718, in call
await route.handle(scope, receive, send)
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\starlette\routing.py", line 276, in handle
await self.app(scope, receive, send)
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\starlette\routing.py", line 66, in app
response = await func(request)
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\fastapi\routing.py", line 237, in app
raw_response = await run_endpoint_function(
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\venv\lib\site-packages\fastapi\routing.py", line 163, in run_endpoint_function
return await dependant.call(**values)
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\extensions\sd-webui-infinite-image-browsing\scripts\api.py", line 349, in match_image_by_tags
ids = [int(x) for x in tag_ids.split(',')]
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\extensions\sd-webui-infinite-image-browsing\scripts\api.py", line 349, in
ids = [int(x) for x in tag_ids.split(',')]
ValueError: invalid literal for int() with base 10: ''

File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\extensions\sd-webui-infinite-image-browsing\scripts\api.py", line 328, in get_db_basic_info
img_count = DbImg.count(conn)
File "C:\Users\bluen\Documents\AI\stable-diffusion-webui\extensions\sd-webui-infinite-image-browsing\scripts\db\datamodel.py", line 106, in count
with closing(conn.cursor()) as cur:
sqlite3.ProgrammingError: SQLite objects created in a thread can only be used in that same thread. The object was created in thread id 11760 and this is thread id 25828.

Dosen't work in sd webui

I have installed the extension,but it dosen't work when I click the tab “inifinite image browsing”,just blank area like below
image

使用gradio链接无法正常加载

Log显示css和js被拦截,但本地版运行正常

GET https://XXXXXX.gradio.live/infinite_image_browsing/fe-static/assets/index-19e73083.css net::ERR_ABORTED 404
GET https://XXXXXX.gradio.live/infinite_image_browsing/fe-static/assets/index-8b7c8e1e.js net::ERR_ABORTED 404

image

FAQ / 常见问题

English

If you encounter any strange issues while using the extension, try upgrading to the latest version of the extension first. Because before you even noticed the problem, I may have already fixed most of them.

How to Disable Access Control Mode

Please refer to https://github.com/zanllp/sd-webui-infinite-image-browsing/blob/main/.env.example to create a .env file and modify the corresponding value (IIB_ACCESS_CONTROL=disable). If you are unable to create and view the .env file in your runtime environment (such as JupyterLab), you can set the environment variable using other methods, as described in the link below.

If you have other questions, please refer to the following two links:
#284
#336

How to add custom folders to IIB so that these folders can also support search

Only folders added to the search scan path will be indexed by IIB, allowing them to be searched and tagged.

image image

Extension failed to load

You can try the following steps in order:

  1. Refresh the page , restart SD-WebUI.
  2. Upgrade this extension to the latest version.
  3. If the problem still persists or you are not using this locally, you can refer to the following two issues for resolution: #84 #79 #410.
  4. If the issue persists, please create a new issue.

The tags are lost after migrating the folder path.

https://github.com/zanllp/sd-webui-infinite-image-browsing/wiki/Proper-Folder-Migration-to-Avoid-Data-Loss---%E6%AD%A3%E7%A1%AE%E7%9A%84%E8%BF%81%E7%A7%BB%E6%96%87%E4%BB%B6%E5%A4%B9%E9%81%BF%E5%85%8D%E6%95%B0%E6%8D%AE%E4%B8%A2%E5%A4%B1

When sent to other tabs, the loading icon keeps spinning

Refer to AUTOMATIC1111/stable-diffusion-webui#9150. Although it looks different, the problem is actually the same.

How to open the right-click menu on mobile devices?

You need to enable "Support long press to open right-click menu" in the global settings first, and then use long press to perform the operation instead of right-clicking to open the right-click menu.

image

How can I control the sorting/display mode/copy the current page path/move to a specific folder?

You can choose the sorting method in the upper-right corner of the TabPane

More

image

中文

如果您在使用拓展的过程中遇到了一些奇怪的问题,可以先尝试升级到最新版本的拓展。因为在您发现问题之前,我可能已经解决了大部分问题。

想要关闭访问控制模式

参考 https://github.com/zanllp/sd-webui-infinite-image-browsing/blob/main/.env.example 创建.env文件然后修改对应值(IIB_ACCESS_CONTROL=disable)即可。 如果你的运行环境无法创建&查看.env文件(例如jupyterlab),你可以通过其他设置环境变量的方法,具体参考下面的链接

如果有其他问题也可以先参考下面两个链接。
#284
#336

如何添加自定义的文件夹到IIB,让这些文件夹也能支持搜索

只有添加到搜索扫描路径的文件夹IIB才会给你生成索引,才能被搜索到和打标签

image image

拓展没能正确加载

你可以按照以下的顺序进行尝试

  1. 刷新页面,重启sd-webui
  2. 升级本拓展到最新版本
  3. 如果还是有问题或者你不是在本地使用,你可以参考下面这两个issue来解决。#84 #79 #410
  4. 如果还是不行创建一个issue

迁移文件夹路径后tag丢失

https://github.com/zanllp/sd-webui-infinite-image-browsing/wiki/Proper-Folder-Migration-to-Avoid-Data-Loss---%E6%AD%A3%E7%A1%AE%E7%9A%84%E8%BF%81%E7%A7%BB%E6%96%87%E4%BB%B6%E5%A4%B9%E9%81%BF%E5%85%8D%E6%95%B0%E6%8D%AE%E4%B8%A2%E5%A4%B1

发送到其他tab时,loading一直转

参考 AUTOMATIC1111/stable-diffusion-webui#9150 , 虽然长的不太一样但实际上问题的原因是同一个

在移动端如何打开右键菜单?

你必须先在全局设置中把“支持使用长按打开右键菜单”打开,然后使用长按进行操作,即可代替右键打开右键菜单

image

如何控制排序/显示模式/复制当前页面路径/移动至指定文件夹?

您可以在 TabPane 的右上角点击更多。

Feature request: Prompts when viewing an image and Right-click menu on big image.

It is very necessary to see the generation info (prompts, etc) when an image is open. We can flip through images with arrows, it would be very convenient for the artist to see how the prompt changes. Now it is VERY inconvenient to see the generation info - you have to make several clicks for each picture.

There also needs to be a copy button for the generation info and a right-click menu with the same options as the right-click menu on the preview pictures.

Probably, it is necessary to make this text block optional, so that those who don't need it could disable it.

browser
browser-right-click

[Bug] LoRA text not indexed for image search

I have the following LoRA usage in some of my images: <lora:AnyaTaylorJoy_v1.11.0:0.6>. When I index my images (even when completely rebuilding it, by deleting the database), the LoRA isn't recognized and doesn't show up as a tag.
Something like <lora:epiNoiseoffset_v2:0.3> isn't indexed either.

Is it because of the weights or something?

Bug: the walk mode shows the wrong directories for extra and save

By default, Extra and Save directories do not have subdirectory structure as txt2img and img2img directories do. When a directory does not have subdirectory such as "2023-05-08", this extension shows the subdirectories of other random irrelevant directories in the walk mode.

For example, it shows "2023-05-09" directory in the walk mode for save directory although the directory does not have it. If I click it, it will forward me to the subdirectory of img2img or txt2img.

I am running SD on Linux. If this problem does not happen in other OS, it might be a path handling issue.

Fix needed on the new save image feature

Thanks for implementing that Save button as quickly as you did ! Exactly what I was looking for :)
But I noticed a small issue, you can only save one image at the time, no matter how many you've selected and it'll always be the image clicked on, not even the last selected!

Also, is there an option somewhere to set a custom folder for the saved pictures?

[问题反馈] 完全无法使用

image

无论点击什么快速启动, 都显示这个错误提示, 并展示一个文件浏览界面, 但是什么文件夹也打不开

Feature Request

Thank you for this nice extention ;-)

I would like to Request a Feature for adding filters for the images showing, for example new to old or old to new so it arrange the images based on date of creation from up to down or the other way around.

Exception in ASGI application while deleting an Image: sqlite3.OperationalError: database is locked

I encountered an exception in the ASGI application while trying to delete an Image. The traceback points to an sqlite3.OperationalError, indicating that the database is locked.

Traceback (most recent call last):
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/uvicorn/protocols/http/h11_impl.py", line 428, in run_asgi
    result = await app(  # type: ignore[func-returns-value]
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/uvicorn/middleware/proxy_headers.py", line 78, in __call__
    return await self.app(scope, receive, send)
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/fastapi/applications.py", line 273, in __call__
    await super().__call__(scope, receive, send)
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/starlette/applications.py", line 122, in __call__
    await self.middleware_stack(scope, receive, send)
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/starlette/middleware/errors.py", line 184, in __call__
    raise exc
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/starlette/middleware/errors.py", line 162, in __call__
    await self.app(scope, receive, _send)
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/starlette/middleware/gzip.py", line 24, in __call__
    await responder(scope, receive, send)
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/starlette/middleware/gzip.py", line 44, in __call__
    await self.app(scope, receive, self.send_with_gzip)
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/starlette/middleware/exceptions.py", line 79, in __call__
    raise exc
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/starlette/middleware/exceptions.py", line 68, in __call__
    await self.app(scope, receive, sender)
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/fastapi/middleware/asyncexitstack.py", line 21, in __call__
    raise e
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/fastapi/middleware/asyncexitstack.py", line 18, in __call__
    await self.app(scope, receive, send)
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/starlette/routing.py", line 718, in __call__
    await route.handle(scope, receive, send)
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/starlette/routing.py", line 276, in handle
    await self.app(scope, receive, send)
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/starlette/routing.py", line 66, in app
    response = await func(request)
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/fastapi/routing.py", line 237, in app
    raw_response = await run_endpoint_function(
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/venv/lib/python3.8/site-packages/fastapi/routing.py", line 163, in run_endpoint_function
    return await dependant.call(**values)
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/extensions/sd-webui-infinite-image-browsing/scripts/api.py", line 68, in delete_files
    conn = DataBase.get_conn()
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/extensions/sd-webui-infinite-image-browsing/scripts/db/datamodel.py", line 28, in get_conn
    conn = clz.init()
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/extensions/sd-webui-infinite-image-browsing/scripts/db/datamodel.py", line 36, in init
    Floder.create_table(conn)
  File "/mnt/batch/tasks/shared/LS_root/mounts/clusters/diffusion/code/Users/yaman/stable-diffusion-webui/extensions/sd-webui-infinite-image-browsing/scripts/db/datamodel.py", line 369, in create_table
    cur.execute(
sqlite3.OperationalError: database is locked```

[功能建议]优化多选操作及prompt显示

非常非常好用 但是有两个小问题
第一个是 按住shift和ctrl多选的时候 如果发现最后的时候选多了不能取消选中 那就要整个重新选了
第二个是 希望点开浏览大图的时候在上面增加一个文本框 来显示图片的prompt等信息 这样能进行更加方便直观的对比

Feature request: Add password protection to the url

With the automatic1111 web ui you have the option to use these parameters:
--listen --gradio-auth someUsername:somePassword
This broadcasts web ui in the lan and allows other computers to connect with it, but once they do, they have to input the correct username and password. However this extension broadcasts a url like: http://192.168.0.12:7860/infinite_image_browsing which does not use the gradio auth username and password. This is a security issue, as simply having the correct url means anyone can view (and delete) any and every file on your device. If someone knows you use stable diffusion, it's not a difficult thing to guess.

Please add an option to either:

  1. Disable the ability to access this extension directly through a url
  2. Add password protection to the url

Note this should also apply to every other api access as well, such as:
http://192.168.0.12:7860/infinite_image_browsing/file?filename=C%3A%5Csd-outputs%5Cimage.png

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.