Closed SleLaugh closed 1 year ago
By the way, in the version that can load dicom properly, the log output "[Dicom Model-pool-2-thread-1] org.opencv.osgi: Successfully loaded OpenCV native library."
In the version that cannot load the dicom properly, no matter how I open the dicom operation, there will be no log statement output
I can't reproduce the problem on Windows 2012 R2. If OpenCV fails to load, you should see this in the log output. Please provide logs (default.log) when you open DICOM file because the logs above don't give any clue about the issue.
I have faced this issues for for different radiologist and end up with older versions. today I have connected with surface pro windows 11 pc and latest version was not loading images and installed 3.8 version works fine. it is really major issue. Kindly do the needful.
I can't reproduce the problem on Windows 2012 R2. If OpenCV fails to load, you should see this in the log output. Please provide logs (default.log) when you open DICOM file because the logs above don't give any clue about the issue.
Of course, I'd be happy to offer it to you. 4.0.3 boot-0.0.log 4.0.3 default.log 4.1.2 boot-0.0.log 4.1.2 default.log
我无法在 Windows 2012 R2 上重现该问题。如果 OpenCV 加载失败,您应该在日志输出中看到这一点。当您打开 DICOM 文件时,请提供日志 (default.log),因为上面的日志没有提供有关该问题的任何线索。
当然,我很乐意将其提供给您。 4.0.3 boot-0.0.log 4.0.3 default.log 4.1.2 boot-0.0.log 4.1.2 default.log
At the same time, although 4.1.2 does not load DICOM, the load icon in the lower left corner will flash
It's really amazing because there are no errors and some plugins don't seem to be launched. I've never seen this before.
Could provide the output of the OSGI console that will give the status of all the plugins, start Weasis and type in a prompt:
telnet localhost 17179
lb
It's really amazing because there are no errors and some plugins don't seem to be launched. I've never seen this before.
Could provide the output of the OSGI console that will give the status of all the plugins, start Weasis and type in a prompt:
telnet localhost 17179
lb
This is the output of the OSGI console. 4.0.3 4.1.2
And I tweaked my test procedure and found some new clues.
After I opened weasis for the first time and set default.log, I deleted the log opened this time.
I then restarted weasis and opened DICOM.
Here is the new log. 4.0.3 boot-0.0.log 4.0.3 default.log 4.1.2 boot-0.0.log 4.1.2 default.log
After comparison, I found that in the version (4.1.2) where the image cannot be opened, the two sentences "INFO [FelixStartLevel] org.weasis.core.internal.cv.NativeOpenCVCodec: Native OpenCV is activated","INFO [FelixStartLevel] org.weasis.core.internal.Activator: Register Image Codec Plug-in: OpenCV imgcodecs"are missing in default.log. They are available in default.log in 4.0.3.
I hope this clue will help you.
It is like the weasis-core-img-4.6.1-jdk11.jar.xz package is corrupted because it is Active in the OSGI console "Image Processing (OpenCV) 4.6.1" but we do not see the initialisation in the logs.
Could you try to delete cache folder in your user ".weasis/cache-id" (replace id by the one in boot.log Application Source ID = B130CF7D) and the restart. Or delete the whole .weasis folder.
It is like the weasis-core-img-4.6.1-jdk11.jar.xz package is corrupted because it is Active in the OSGI console "Image Processing (OpenCV) 4.6.1" but we do not see the initialisation in the logs.
Could you try to delete cache folder in your user ".weasis/cache-id" (replace id by the one in boot.log Application Source ID = B130CF7D) and the restart. Or delete the whole .weasis folder.
Sorry, I'm a little confused. You mean that the ".weasis" cache folder generated by the previous test version is deleted before each version test?
If this is the case, then before this, every test I have done has been to delete the previous ".weasis" folder and then test. This means that there are no cached folders for each test, as they are all reloaded in this round of tests.
If not, please provide more detailed test procedures.
If you delete .weasis folder it will clean all the preferences and some cache for osgi. So it will be the same state when you run Weasis for the very first time on a Windows session. In general when package is corrupted in the osgi cache, weasis will automatically clean at next start but in your case there is no apparent error. So that's why I asking to delete manually.
My steps are as follows:
Delete the "C/.weasis" folder
Open weasis4.1.2
Set default.log
Open the image and observe defalut.log. No exception log is displayed
Close weasis4.1.2 and delete the "cache-B130CF7D" folder
Open weasis
Open the image and look at defalut.log. Some exception logs are observed, but they don't seem to have much to do with openCV
I repeated steps 4-7 many times
I hope these things work
Okay, the package doesn't seem to be corrupted. I've modified the library to log all the errors, not just RuntimeError. Follow this instructions:
Download this file weasis-core.zip
Unzip the file
Replace this weasis-core-img-4.6.1-jdk11.jar.xz
with one installed in program folder.
Delete again .weasis
folder, restart Weasis and check logs
There are indeed abnormal log outputs.
When opening weasis, boot.log has abnormal information output: "SEVERE [FelixStartLevel] org.opencv.osgi: Cannot load OpenCV native library: C:\Users\Administrator.weasis\cache-B130CF7D\bundle37\version0.0\bundle.jar-lib\0\opencv_java.dll: Can’t find dependent libraries".
Then, I performed the open DICOM operation, and it will load the DICOM, although what is loaded is error information.
At the same time, there is also abnormal information output, please see the log file for details. boot-0.0.log default.log
Before replacing the weasis-core you provided, there was no content loaded when performing the open DICOM operation.
But please note that under the same environment, when opening versions below weasis4.0.3 (including 4.0.3), the DICOM can be opened normally.
I’m glad we’ve made some progress.
Dear sir, I used to install older version like 3.8.1 then if we upgrade to 4.1 it used to work. some thing need to fix and resolve.
Now the problem is clear: opencv_java.dll is missing some dependencies.
First, I'll propose modifying the initialization in the opencv project because this error is not caught.
According to the documentation, the latest build requires: If the import fails on Windows, make sure you have Visual C++ redistributable 2015 installed. If you are using older Windows version than Windows 10 and latest system updates are not installed, Universal C Runtime might be also required.
For systems prior to Windows 10 they are already end of life, it should no longer be used. For Windows 2012 R2, there are 3 months left before EOL.
Now the problem is clear: opencv_java.dll is missing some dependencies.
First, I'll propose modifying the initialization in the opencv project because this error is not caught.
I'm glad you found the problem According to the documentation, the latest build requires: If the import fails on Windows, make sure you have Visual C++ redistributable 2015 installed. If you are using older Windows version than Windows 10 and latest system updates are not installed, Universal C Runtime might be also required.
After I tried to install Visual C++ redistributable 2015, it worked fine. I hope you can solve this problem in the next version. But what explains why version 4.0.3 works?
For systems prior to Windows 10 they are already end of life, it should no longer be used. For Windows 2012 R2, there are 3 months left before EOL.
For some hospitals, they will still choose to use windows 7,, which is inevitable, but in most cases it will still be windows 10.
Unfortunately, there's no clear information on these developments, and I can't see any obvious change in the construction of the binaries.
I'll have a look, but I don't think I'll be able to change that, as it's in OpenCV and seems to be part of the library's evolution. As it's already a lot of effort to get Weasis supported on many systems and architectures, it's obvious that end-of-life systems can't be supported.
However, I'll update the requirement in the download comment.
No matter what the outcome, thank you for your dedication and support.
Weasis 4.2.0 will use a new release of opencv without a Visual C++ redistributable 2015 dependency.
Describe the bug. What happened?
I found a bug.
In some environments, weasis versions later than 4.0.3 cannot load dicom.
I tried the following versions: 4.0.1, 4.0.2, 4.0.3, 4.1.0, 4.1.1, 4.1.2. These versions are installed after downloading the windows installation package, rather than compiling through code.
When I opened the dicom or dragged the dicom onto the weasis form, the first three versions loaded the dicom correctly, but the last three failed to load the dicom properly.
So I looked at their logs.
I found that versions that load dicom correctly, after starting weasis, will always have a sentence at the end of the log "[FelixStartLevel] org.opencv.osgi: Successfully loaded OpenCV native library ", and the version that failed to load dicom does not output this sentence in the log. So I wonder if it is because OpenCV is not loaded correctly that the dicom cannot be loaded.
Note: I tested the above six versions in three environments, one of which was my own machine (windows10) and the other two were VMware virtual machines (windows server 2012R2).
In one of the virtual machines and my local environment, the above 6 versions can load OpenCV and load dicom correctly, and when I check their logs, they all output the log of OpenCV loading success;
Another virtual machine, the first three versions are normal output OpenCV loading success log, and can also open the dicom , while the latter three versions do not output OpenCV loading success log, and can not load the dicom .
I've had this problem with windows7.
At that time it was like this: there were two computers with windows7, but one of them could not load dicom properly, and the other could load dicom normally. The weasis version at the time was a bit higher than the 4.0.3 environment and was compiled from code in March 2023.
I didn't care at the time, but now I think OpenCV didn't load successfully.
I'm a java novice, sorry if I'm wrong.
My English is not very good, if you are not clear, please reply me, I will try my best to express more clearly.
What version of Weasis are you running?
4.1.2
On which system the problem occurs?
Windows
Relevant log output
Additional contextual elements
No response