improve readme.md and configs util functions
This commit is contained in:
@@ -21,7 +21,6 @@ from .nHHD import nHHD
|
||||
from . import configs
|
||||
from .get_depth import Contact3D
|
||||
|
||||
|
||||
class Sensor:
|
||||
"""
|
||||
Optical tactile sensor interface with deformation analysis.
|
||||
@@ -200,7 +199,7 @@ class Sensor:
|
||||
if self.mirror:
|
||||
self.__img = cv2.flip(self.__img, 1)
|
||||
|
||||
return True
|
||||
return self.__img.copy()
|
||||
|
||||
def compute_deformation(self):
|
||||
"""
|
||||
@@ -228,7 +227,6 @@ class Sensor:
|
||||
if hasattr(flow, 'download'):
|
||||
flow = flow.download()
|
||||
self.__flow = flow
|
||||
return True
|
||||
|
||||
def __compute_hhd(self):
|
||||
|
||||
@@ -358,12 +356,14 @@ class Sensor:
|
||||
# Public API - Configuration & Calibration
|
||||
# =========================================================================
|
||||
|
||||
def export_config(self, path="./config/exported_config.json"):
|
||||
"""Return current configuration dict."""
|
||||
configs.export_config(self._config, path)
|
||||
if self.verbose:
|
||||
print(f"Config exported to {path}")
|
||||
return True
|
||||
# def export_config(self, path="./config/exported_config.json"):
|
||||
# """Return current configuration dict."""
|
||||
# configs.export_config(self._config, path)
|
||||
# if self.verbose:
|
||||
# print(f"Config exported to {path}")
|
||||
# return True
|
||||
|
||||
|
||||
|
||||
def stitch_cal(self):
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user