Comments (5)
用 Files to process 指定就行了
from sd-webui-image-sequence-toolkit.
用 Files to process 指定就行了
我输入了输入文件夹的某一个文件名,扩展名删掉也试了都会出现FileNotFoundError错误
line 220, in run
raise FileNotFoundError
from sd-webui-image-sequence-toolkit.
用 Files to process 指定就行了
我输入了输入文件夹的某一个文件名,扩展名删掉也试了都会出现FileNotFoundError错误 line 220, in run raise FileNotFoundError
只处理一张要用 文件名-文件名
的形式
from sd-webui-image-sequence-toolkit.
用 Files to process 指定就行了
我输入了输入文件夹的某一个文件名,扩展名删掉也试了都会出现FileNotFoundError错误 line 220, in run raise FileNotFoundError
只处理一张要用
文件名-文件名
的形式
00001.png-00001.png或者00001.png-00002.png
我按了这个输入的,是输入文件夹的图片,还是报那个错用逗号也一样
from sd-webui-image-sequence-toolkit.
我参考chatgpt修改了这部分代码,运行是可以的, 只做了一种情况,就是单个文件名,从这个文件处理到结束。
就是这里下标[2]才是开始处理的图片,有点怪但是不影响把
reference_imgs = [images_in_folder_dict[start - interval_img], images_in_folder_dict[max(0, start - interval_img)]] + images
if given_file:
images = []
images_in_folder = [os.path.join(input_dir, f) for f in os.listdir(input_dir) if re.match(r'.+\.(jpg|png)$', f)]
try:
images_idx = [int(re.findall(re_findidx, j)[0]) for j in images_in_folder]
except BaseException:
images_idx = [re.findall(re_findname, j)[0] for j in images_in_folder]
images_in_folder_dict = dict(zip(images_idx, images_in_folder))
sep = ',' if ',' in specified_filename else ' '
print("aaaaaaaaaaaaa")
print(images_idx)
images_idx = sorted(images_idx)
interval_img = images_idx[1] - images_idx[0]
start = None
print(images_in_folder_dict.values())
for i in specified_filename.split(sep):
for value in images_in_folder_dict.values():
if i in value:
images.append(value)
print("ddddddddddddddd")
if len(specified_filename.split(sep)) == 1:
end = images_idx[-1]
else:
end = i
if not start:
start = i
else:
try:
match = re.search(r'(^\d*)-(\d*$)', i)
if match:
start, end = match.groups()
if start == '':
start = images_idx[0]
if end == '':
end = images_idx[-1]
images += [images_in_folder_dict[j] for j in list(range(int(start), int(end) + 1))]
except BaseException:
try:
images.append(images_in_folder_dict[int(i)])
except KeyError:
pass
if len(images) == 0:
raise FileNotFoundError(f"No valid image found in specified file: {specified_filename}")
start = int(start.split('.')[0].lstrip('0'))
if isinstance(end, int):
end = str(end)
end = int(end.split('.')[0].lstrip('0'))
images += [images_in_folder_dict[j]
for j in list(range(int(start + interval_img), int(end) + interval_img, interval_img))]
reference_imgs = [images_in_folder_dict[start - interval_img], images_in_folder_dict[max(0, start - interval_img)]] + images
history_imgs = [images_in_folder_dict[images_idx[0]], images_in_folder_dict[max(images_idx[0], start - 2*interval_img)], images_in_folder_dict[max(0, start - interval_img)]]
history_imgs = [images_in_folder_dict[images_idx[0]]] + [os.path.join(output_dir, os.path.basename(f)) for f in history_imgs]`
```
from sd-webui-image-sequence-toolkit.
Related Issues (20)
- If with command --listen, plug-in will show error HOT 1
- enhanced_img2img, 在没有勾选"Use another image as ControlNet input"时出错 HOT 1
- AssertionError when using "Use another image as ControlNet input" HOT 2
- How can I do this ? input 1 : a directory of images to batch img2img process to upscale into 2x, another directory of images to apply controlnet for this process? the image names can be same for the script
- Add mov2mov support
- ValueError: images do not match HOT 1
- Cannot reproduce bilibili result
- is "use deepbooru prompt function" no more?
- [BUG] 最近几天第一帧似乎吃不到ControlNET,不知道是哪边的问题 HOT 1
- Error with deepdanbooru attribute in enhanced_img2img.py
- 用api调用多帧渲染的脚本的时候报错
- AttributeError: 'NoneType' object has no attribute 'group' HOT 2
- Enhanced img2img missing script?
- RuntimeError regarding the number of images when Loopback is enabled
- video question
- MFR貌似漏写了一行msk
- p.control_net_input_image deprecated
- 多帧重绘指定第三列图片#feature request
- Getting IndexError: list index out of range
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sd-webui-image-sequence-toolkit.