|
Post by lfec on Jan 18, 2016 2:52:51 GMT
is there a way so i could measure the energy efficiency on Ankulua?
I noticed my battery goes down faster than just playing, and that's expected, a program can't be acting endlessly or searching endlessly without spending energy.
But i want to reduce this inefficiency.
i have already reduced the search area with region and removed the wait click
function waitOneScan(zona, target) while (true) do if (zona:exists(target, 0)) then return getLastMatch() end wait(10) end end
zona = Region(0,720, 640,130) found = waitOneScan(zona, button) click(found)
Someone have any idea?
|
|
|
Post by AnkuLua on Jan 18, 2016 3:48:38 GMT
is there a way so i could measure the energy efficiency on Ankulua? I noticed my battery goes down faster than just playing, and that's expected, a program can't be acting endlessly or searching endlessly without spending energy. But i want to reduce this inefficiency. i have already reduced the search area with region and removed the wait click function waitOneScan(zona, target) while (true) do if (zona:exists(target, 0)) then return getLastMatch() end wait(10) end end
zona = Region(0,720, 640,130) found = waitOneScan(zona, button) click(found)
Someone have any idea? You already do very good on reducing scan rate to every ten seconds if not found the target. There is one problem in your script, however. getLastMatch() is combined with region. Therefore, you should return zona:getLastMatch() if (zona:exists(target, 0)) then
return zona:getLastMatch()
end
|
|
|
Post by lfec on Jan 18, 2016 10:08:47 GMT
already do very good on reducing scan rate to every ten seconds if not found the target. There is one problem in your script, however. getLastMatch() is combined with region. Therefore, you should return zona:getLastMatch() i got a odd behavior in my code, zona:getLastMatch() solved it. --Edit-- The code you posted in here did all the work, just added the region for a increase in performance
|
|
|
Post by lfec on Jan 21, 2016 11:49:06 GMT
if my regions, instead of a area of search, be of the exact size of my pattern, would it reduce my scan to only one check?
|
|
|
Post by AnkuLua on Jan 21, 2016 13:00:13 GMT
if my regions, instead of a area of search, be of the exact size of my pattern, would it reduce my scan to only one check? Can't really catch your idea. For energy efficiency, the only way is to use "wait( seconds)" The script keeps running next search after finishing previous search, if that's what your script written in that way. In fact, using region search increase the scan rate. It reduce the time for image recognition and ready for starting next screenshot. And, it's nothing related with reducing power.
|
|
|
Post by lfec on Jan 21, 2016 13:36:29 GMT
i was thinking something more or less like, the smaller the search area --> less cpu/gpu processing --> less power consuption.
I only know the basic of image processing, the image search i learned was like this, put the target over the image in 0,0, do it match? No, try 0,1 and so on.
So the larger my region, the more the program has to search.
that's why i thought about reducing it to the 2-3 only position the button can be. i would reduce power consuption.
Do you think it's worth?
|
|
|
Post by AnkuLua on Jan 21, 2016 13:44:17 GMT
i was thinking something more or less like, the smaller the search area --> less cpu/gpu processing --> less power consuption. I only know the basic of image processing, the image search i learned was like this, put the target over the image in 0,0, do it match? No, try 0,1 and so on. So the larger my region, the more the program has to search. that's why i thought about reducing it to the 2-3 only position the button can be. i would reduce power consumption. Do you think it's worth? That's what I am talking about. The answer is no and yes. If the script starts next target search after finishing current one immediately, the answer is no. But the answer is yes if more wait time. ---- EDIT ------ After thinking more, something to add. You can majorly divide the CPU loading of AnkuLua intto two parts. 1. screenshot 2. image recognition Without adding more wait time, smaller search area mean smaller percent of CPU on image recognition, but larger on screenshot. It will depends on the difference of consumed energy by screenshot and image recognition for the same amount of time.
|
|
|
Post by AnkuLua on Jan 31, 2016 14:55:09 GMT
|
|
|
Post by lfec on Jan 31, 2016 15:11:29 GMT
thanks, will check it.
|
|