thy960112 / mdbn Goto Github PK
View Code? Open in Web Editor NEWLicense: MIT License
License: MIT License
Hello, may I ask how to solve the problem "ModuleNotFoundError: No module named 'basicsr.archs.vgg_arch'".Thank you very much.
in basic_loss.py
import torch
from torch import nn as nn
from torch.nn import functional as F
from basicsr.archs.vgg_arch import VGGFeatureExtractor
from basicsr.utils.registry import LOSS_REGISTRY
from .loss_util import weighted_loss
Do I need to define a vgg_arch myself?
你好,请问数据集要怎么设置
$ python basicsr/test.py -opt options/test/MDBN/test_MDBN_x2.yml
C:\Python310\lib\site-packages\torchvision\transforms\functional_tensor.py:5: UserWarning: The torchvision.transforms.functional_tensor module is deprecated in 0.15 and will be **removed in 0.17**. Please don't rely on it. You probably just need to use APIs in torchvision.transforms.functional or in torchvision.transforms.v2.functional.
warnings.warn(
Disable distributed.
Path already exists. Rename it to C:\MDBN-main\results\001_MDBN_x2_archived_20231009_203813
2023-10-09 20:38:13,476 INFO:
____ _ _____ ____
/ __ ) ____ _ _____ (_)_____/ ___/ / __ \
/ __ |/ __ `// ___// // ___/\__ \ / /_/ /
/ /_/ // /_/ /(__ )/ // /__ ___/ // _, _/
/_____/ \__,_//____//_/ \___//____//_/ |_|
______ __ __ __ __
/ ____/____ ____ ____/ / / / __ __ _____ / /__ / /
/ / __ / __ \ / __ \ / __ / / / / / / // ___// //_/ / /
/ /_/ // /_/ // /_/ // /_/ / / /___/ /_/ // /__ / /< /_/
\____/ \____/ \____/ \____/ /_____/\____/ \___//_/|_| (_)
Version Information:
BasicSR: 1.4.2
PyTorch: 2.0.1+cu118
TorchVision: 0.15.2+cu118
2023-10-09 20:38:13,476 INFO:
name: 001_MDBN_x2
model_type: SRModel
scale: 2
num_gpu: 1
manual_seed: 2023
datasets:[
test_1:[
name: Set5
type: PairedImageDataset
dataroot_gt: datasets/Set5/GTmod12
dataroot_lq: datasets/Set5/LRbicx2
io_backend:[
type: disk
]
phase: test
scale: 2
]
]
network_g:[
type: MDBN
num_in_ch: 3
num_out_ch: 3
num_feat: 64
num_block: 6
upscale: 2
res_scale: 1.0
]
path:[
pretrain_network_g: experiments/pretrained_models/MDBN_x2.pth
strict_load_g: True
results_root: C:\MDBN-main\results\001_MDBN_x2
log: C:\MDBN-main\results\001_MDBN_x2
visualization: C:\MDBN-main\results\001_MDBN_x2\visualization
]
val:[
save_img: True
suffix: None
metrics:[
psnr:[
type: calculate_psnr
crop_border: 4
test_y_channel: ture
]
ssim:[
type: calculate_ssim
crop_border: 4
test_y_channel: ture
]
]
]
dist: False
rank: 0
world_size: 1
auto_resume: False
is_train: False
2023-10-09 20:38:13,476 INFO: Dataset [PairedImageDataset] - Set5 is built.
2023-10-09 20:38:13,476 INFO: Number of test images in Set5: 2
Name MDBN is not found, use name: MDBN_basicsr!
Traceback (most recent call last):
File "C:\MDBN-main\basicsr\test.py", line 45, in <module>
test_pipeline(root_path)
File "C:\MDBN-main\basicsr\test.py", line 35, in test_pipeline
model = build_model(opt)
File "C:\Python310\lib\site-packages\basicsr\models\__init__.py", line 26, in build_model
model = MODEL_REGISTRY.get(opt['model_type'])(opt)
File "C:\Python310\lib\site-packages\basicsr\models\sr_model.py", line 22, in __init__
self.net_g = build_network(opt['network_g'])
File "C:\Python310\lib\site-packages\basicsr\archs\__init__.py", line 22, in build_network
net = ARCH_REGISTRY.get(network_type)(**opt)
File "C:\Python310\lib\site-packages\basicsr\utils\registry.py", line 71, in get
raise KeyError(f"No object named '{name}' found in '{self._name}' registry!")
KeyError: "No object named 'MDBN' found in 'arch' registry!"
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.