sikuli script stops randomly with the following error: org.opencv.core.CvException: CvException [org.opencv.core.CvException: cv::Exception: OpenCV(3.4.2)

Asked by reda benslal

im using a sikuli script that is executed on a host machine (Windows 7 64) using sikuli 2.0.4. the script monitors changes of a program that is run on a windows 7 64 VM. though out the execution, the script tends to shut down randomly with these error messages:

[07:55:45][Step 16/17] File "C:\cp\trv\IVV\TeamCity scripts\eZ_SETUP_Validation_Automated_Tests\VM_OS_W7_EN\TC_scripts\start_ATS_eZ.sikuli\start_ATS_eZ.py", line 61, in <module>
[07:55:45][Step 16/17] if exists("1560158467995-2.png",3): #popup for xma_simu
[07:55:45][Step 16/17]
[07:55:45][Step 16/17] at org.opencv.imgproc.Imgproc.matchTemplate_1(Native Method)
[07:55:45][Step 16/17] at org.opencv.imgproc.Imgproc.matchTemplate(Imgproc.java:2616)
[07:55:45][Step 16/17] at org.sikuli.script.Finder$Finder2.doFindMatch(Finder.java:733)
[07:55:45][Step 16/17] at org.sikuli.script.Finder$Finder2.doFindImage(Finder.java:704)
[07:55:45][Step 16/17] at org.sikuli.script.Finder$Finder2.doFind(Finder.java:622)
[07:55:45][Step 16/17] at org.sikuli.script.Finder$Finder2.find(Finder.java:582)
[07:55:45][Step 16/17] at org.sikuli.script.Finder.findRepeat(Finder.java:109)
[07:55:45][Step 16/17] at org.sikuli.script.Region.doFind(Region.java:2720)
[07:55:45][Step 16/17] at org.sikuli.script.Region.access$200(Region.java:28)
[07:55:45][Step 16/17] at org.sikuli.script.Region$RepeatableFind.run(Region.java:2983)
[07:55:45][Step 16/17] at org.sikuli.script.Region$Repeatable.repeat(Region.java:2926)
[07:55:45][Step 16/17] at org.sikuli.script.Region.exists(Region.java:2322)
[07:55:45][Step 16/17] at sun.reflect.GeneratedMethodAccessor20.invoke(Unknown Source)
[07:55:45][Step 16/17] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
[07:55:45][Step 16/17] at java.lang.reflect.Method.invoke(Unknown Source)
[07:55:45][Step 16/17] org.opencv.core.CvException: CvException [org.opencv.core.CvException: cv::Exception: OpenCV(3.4.2) C:\build\3_4_winpack-bindings-win64-vc14-static\opencv\modules\core\src\matrix.cpp:367: error: (-215:Assertion failed) u != 0 in function 'cv::Mat::create'

i looked arround and found similar cases where these error messages are being reported; the issue that is mostly discussed is memory shortage, and how it impacts openCV. so since i was running the VM with 23G RAM, i decreased it to 8G to provide the host with more RAM . unfortunatly that did not help much. i then, tried the to decrease the size of the image where the error is triggered as suggested here: https://answers.launchpad.net/sikuli/+question/676631 yet again the error messages were still getting reported.

are there any tips you could give me to help overcome this ? or maybe alterations in within the script code if necessary?
thanks in advance .

Question information

Language:
English Edit question
Status:
Expired
For:
SikuliX Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Launchpad Janitor (janitor) said :
#1

This question was expired because it remained in the 'Open' state without activity for the last 15 days.