Scheduled service maintenance on November 22


On Friday, November 22, 2024, between 06:00 CET and 18:00 CET, GIN services will undergo planned maintenance. Extended service interruptions should be expected. We will try to keep downtimes to a minimum, but recommend that users avoid critical tasks, large data uploads, or DOI requests during this time.

We apologize for any inconvenience.

orphan_functions.py 778 B

123456789101112131415161718
  1. from view.python_core.rois.iltis_rois.text_based import CircleILTISROIData, PolygonILTISROIData
  2. from iltis.Objects.ROIs_Object import myPolyLineROI, myCircleROI
  3. def convert_iltisROI2VIEWROI(roi):
  4. if type(roi) == myCircleROI:
  5. roi_data = CircleILTISROIData(label=roi.label, x=roi.center[0], y=roi.center[1], d=roi.diameter)
  6. elif type(roi) == myPolyLineROI:
  7. # copied from ILTIS
  8. handle_pos = [tup[1] for tup in roi.getSceneHandlePositions()]
  9. pos_mapped = [roi.ViewBox.mapToView(pos) for pos in handle_pos]
  10. roi_data = PolygonILTISROIData(label=roi.label,
  11. list_of_vertices=[(pos.x(), pos.y()) for pos in pos_mapped])
  12. else:
  13. raise NotImplementedError
  14. return roi_data