Ruff formatting adding commas
This commit is contained in:
parent
8d14aee27c
commit
e28a160b22
1 changed files with 8 additions and 8 deletions
|
|
@ -686,7 +686,7 @@ class SmartScanThing(Thing):
|
||||||
"jpeg_path": jpeg_path,
|
"jpeg_path": jpeg_path,
|
||||||
"cam": cam,
|
"cam": cam,
|
||||||
"logger": logger,
|
"logger": logger,
|
||||||
"metadata_getter": metadata_getter
|
"metadata_getter": metadata_getter,
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
capture_thread.start()
|
capture_thread.start()
|
||||||
|
|
@ -769,7 +769,7 @@ class SmartScanThing(Thing):
|
||||||
jpeg_path: str,
|
jpeg_path: str,
|
||||||
cam: CamDep,
|
cam: CamDep,
|
||||||
metadata_getter: GetThingStates,
|
metadata_getter: GetThingStates,
|
||||||
logger: InvocationLogger
|
logger: InvocationLogger,
|
||||||
) -> None:
|
) -> None:
|
||||||
"""Capture an image and save it to disk
|
"""Capture an image and save it to disk
|
||||||
|
|
||||||
|
|
@ -812,19 +812,19 @@ class SmartScanThing(Thing):
|
||||||
)
|
)
|
||||||
return image, metadata
|
return image, metadata
|
||||||
|
|
||||||
|
def save_capture(
|
||||||
def save_capture(self,
|
self,
|
||||||
jpeg_path: str,
|
jpeg_path: str,
|
||||||
image: np.ndarray,
|
image: np.ndarray,
|
||||||
metadata: dict,
|
metadata: dict,
|
||||||
logger: InvocationLogger
|
logger: InvocationLogger,
|
||||||
) -> None:
|
) -> None:
|
||||||
"""Saving the captured image and metadata to disk
|
"""Saving the captured image and metadata to disk
|
||||||
|
|
||||||
logger warning (via InvocationLogger) is raised if metadata is failed to be added
|
logger warning (via InvocationLogger) is raised if metadata is failed to be added
|
||||||
|
|
||||||
IOError is raised if the file cannot be saved
|
IOError is raised if the file cannot be saved
|
||||||
|
|
||||||
nothing is returned on success"""
|
nothing is returned on success"""
|
||||||
try:
|
try:
|
||||||
Image.fromarray(image.astype("uint8"), "RGB").save(
|
Image.fromarray(image.astype("uint8"), "RGB").save(
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue