mirror of
https://gitee.com/sui-feng-cb/AzurLaneAutoScript1
synced 2026-03-09 18:39:04 +08:00
Upd: Update ShopItem_250814 method predict_valid, use np.max
This commit is contained in:
parent
2ccd1036d6
commit
9d544ae0e8
@ -46,9 +46,13 @@ FILTER = Filter(FILTER_REGEX, FILTER_ATTR)
|
||||
|
||||
|
||||
class ShopItem_250814(Item):
|
||||
"""
|
||||
Calculation result of unsold ship_T2 is 0.36, so 0.3 is taken as threshold,
|
||||
result of sold product is < 0.2
|
||||
"""
|
||||
def predict_valid(self):
|
||||
mean = np.mean(rgb2gray(self.image) > 139)
|
||||
return mean > 0.23
|
||||
mean = np.mean(np.max(self.image, axis=2) > 139)
|
||||
return mean > 0.3
|
||||
|
||||
|
||||
class ShopItemGrid(ItemGrid):
|
||||
|
||||
Loading…
Reference in New Issue
Block a user