SpringMVC02- View resolver and controller

Environmental description JDK 17 SpringMVC 6.0.6 Tomcat 10.0.12 Thymeleaf 3.1.2.RELEASE Environment preparation Add SpringMVC dependency and Thymeleaf dependency: <dependency> <groupId>org.springframework</groupId> <artifactId>spring-context</artifactId> <version>6.0.6</version> </dependency> <dependency> <groupId>org.thymeleaf</groupId> <artifactId>thymeleaf-spring6</artifactId> <version>3.1.2.RELEASE</version> </dependency> Configuring view resolvers and controllers Configure the view resolver and register the corresponding ViewResolver as a Bean (Thymeleaf template view resolver configuration steps: template resolver -> template […]

Resolved Bug: Error: [Vue warn]: Unknown custom element: <my-component> – did you register the component

Blogger Maotouhu () takes you to Go to New World? Blog homepage: Maotouhu’s blog “Complete Column of Interview Questions” Articles with pictures and texts Vivid images Simple and easy to learn! Everyone is welcome to step in~ “IDEA Development Cheats Column” Learn the common operations of IDEA and double your work efficiency~ “Master Golang in […]

ResolvedFailed to start bean documentationPluginsBootstrapper; nested exception .lang.NullPointerEx

Article directory Exception information reason Solution Plan 0 plan 1 Insert image description here Exception information Failed to start bean ‘documentationPluginsBootstrapper’; nested exception is java.lang.NullPointerException 2023-11-10 11:21:44.013 ERROR 44100 — [o-8080-Acceptor] org.apache.tomcat.util.net.Acceptor : Socket accept failed java.nio.channels.AsynchronousCloseException: null at java.base/java.nio.channels.spi.AbstractInterruptibleChannel.end(AbstractInterruptibleChannel.java:202) ~[na:na] at java.base/sun.nio.ch.ServerSocketChannelImpl.end(ServerSocketChannelImpl.java:269) ~[na:na] at java.base/sun.nio.ch.ServerSocketChannelImpl.accept(ServerSocketChannelImpl.java:288) ~[na:na] at org.apache.tomcat.util.net.NioEndpoint.serverSocketAccept(NioEndpoint.java:547) ~[tomcat-embed-core-9.0.68.jar:9.0.68] at org.apache.tomcat.util.net.NioEndpoint.serverSocketAccept(NioEndpoint.java:79) ~[tomcat-embed-core-9.0.68.jar:9.0.68] at org.apache.tomcat.util.net.Acceptor.run(Acceptor.java:129) […]

[Resolved] RuntimeError: CUDA error: device-side assert triggeredCUDA kernel errors might be asynchronous

Problem description The specific error message is ./aten/src/ATen/native/cuda/Loss.cu:240: nll_loss_forward_reduce_cuda_kernel_2d: block: [0,0,0], thread: [0,0,0] Assertion `t >= 0 & amp; & amp ; t < n_classes` failed. ../aten/src/ATen/native/cuda/Loss.cu:240: nll_loss_forward_reduce_cuda_kernel_2d: block: [0,0,0], thread: [1,0,0] Assertion `t >= 0 & amp; & amp; t < n_classes` failed. ../aten/src/ATen/native/cuda/Loss.cu:240: nll_loss_forward_reduce_cuda_kernel_2d: block: [0,0,0], thread: [2,0,0] Assertion `t >= 0 & […]

[Resolved] ValueError: zero-size array to reduction operation minimum which has no identity

Problem description Taking over the previous bug problem, the details are as follows: Traceback (most recent call last): File “embed.py”, line 159, in main() File “embed.py”, line 138, in main (x_wm, y_wm), defense = defense_config.embed(defense=defense, File “/home/visionx/anaconda3/envs/watermark/lib/python3.8/site-packages/mlconfig/config.py”, line 20, in __call__ return self.instantiate(*args, **kwargs) File “/home/visionx/anaconda3/envs/watermark/lib/python3.8/site-packages/mlconfig/config.py”, line 65, in instantiate return func_or_cls(*args, **kwargs) File “/home/visionx/project/Watermark-Robustness-Toolbox/wrt/defenses/watermark/adi.py”, […]

[Resolved] AttributeError: module cv2 has no attribute bgsegm

Question When using cv2.bgsegm.createBackgroundSubtractorMOG() to remove the background, I encounter the following problems: AttributeError: module ‘cv2’ has no attribute ‘bgsegm’ Reason Reason for the error: The extension package contrib is not installed in the python environment used. Solution Can be installed via pip or conda pip install opencv-contrib-python -i https://pypi.tuna.tsinghua.edu.cn/simple If the error is still […]

Bug resolved: Invariant Violation: Element type is invalid: expected a string (for built-in components) or

Blogger Maotouhu () takes you to Go to New World? Blog homepage: Maotouhu’s blog “Complete Column of Interview Questions” Articles with pictures and texts Vivid images Simple and easy to learn! Everyone is welcome to step in~ “IDEA Development Cheats Column” Learn the common operations of IDEA and double your work efficiency~ “Master Golang in […]

[YOLO&Pytorch] YOLO series project theory based on Pytorch starting from scratch + practical deployment 03 VoTT data annotation tool annotation video data set + the whole process of YOLOX model deployment and training (all pitfalls were encountered and successfully resolved)

VOTT data annotation tool annotates data sets and YOLOX model deployment training Download and install VoTT Download and install use Training with YOLOX model Download and configure YOLOX model Train and test with your own data sets Preparing for training: putting our own data set in Training preparation: modify training configuration parameters Start training carry […]

Resolve local variable str referenced before assignment

Table of Contents Resolve local variable ‘str’ referenced before assignment wrong reason Solution 1. Initialize variables before use 2. Make sure you declare the variable before referencing it 3. Check the scope of variables in conclusion Resolve local variable ‘str’ referenced before assignment In Python, ??local variable ‘str’ referenced before assignment?? is a common mistake. […]

async and await: When await processes the new Promise ((resolve, reject) =>{…}) object, the parameters of resolve() will be processed as the return value

The async keyword gives you an easier way to work with asynchronous Promise-based code. Add async to the beginning of a function to make it an asynchronous function. async function myFunction() { // This is an asynchronous function } In an asynchronous function, you can use the await keyword before calling a function that returns […]