mirror of
https://gitee.com/sui-feng-cb/AzurLaneAutoScript1
synced 2026-03-12 08:38:20 +08:00
Fix: [ALAS] Remove the use of np.float
This commit is contained in:
@@ -57,7 +57,7 @@ hm.load_homography(image=np.array(az.device.image))
|
|||||||
class SwipeSimulate:
|
class SwipeSimulate:
|
||||||
def __init__(self, swipe, simulate_count=4):
|
def __init__(self, swipe, simulate_count=4):
|
||||||
self.simulate_count = simulate_count
|
self.simulate_count = simulate_count
|
||||||
self.swipe = np.array(swipe, dtype=np.float)
|
self.swipe = np.array(swipe, dtype=float)
|
||||||
self.swipe_base = self.cal_swipe_base()
|
self.swipe_base = self.cal_swipe_base()
|
||||||
logger.info(self.swipe_base)
|
logger.info(self.swipe_base)
|
||||||
|
|
||||||
|
|||||||
@@ -620,7 +620,7 @@ def rgb2hsv(image):
|
|||||||
Returns:
|
Returns:
|
||||||
np.ndarray: Hue (0~360), Saturation (0~100), Value (0~100).
|
np.ndarray: Hue (0~360), Saturation (0~100), Value (0~100).
|
||||||
"""
|
"""
|
||||||
image = cv2.cvtColor(image, cv2.COLOR_RGB2HSV).astype(np.float)
|
image = cv2.cvtColor(image, cv2.COLOR_RGB2HSV).astype(float)
|
||||||
image *= (360 / 180, 100 / 255, 100 / 255)
|
image *= (360 / 180, 100 / 255, 100 / 255)
|
||||||
return image
|
return image
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user