Open Fatih-Haslak opened 5 months ago
Hi which version of pydantic are you using?
@Fatih-Haslak
from this thread I changed this line: https://github.com/Tlaloc-Es/labelme2yolov7segmentation/blob/7a73573a9500cf12bda235f0e470296106f37988/labelme2yolov7segmentation/datatypes.py#L8
to this:
points: List[conlist(item_type=float, min_length=2, max_length=2)]
And it worked
class LabelMeShape(BaseModel): File "C:\Users\Mert\Desktop\labelme2yolov7segmentation\labelme2yolov7segmentation\datatypes.py", line 8, in LabelMeShape points: List[conlist(float, min_items=2, max_items=2)] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ TypeError: conlist() got an unexpected keyword argument 'min_items'