playground icon indicating copy to clipboard operation
playground copied to clipboard

AttributeError: 'MMDetection' object has no attribute 'value'

Open zym3122 opened this issue 2 years ago • 5 comments

I loaded the SAM back-end in the background, and successfully connected the reasoning model in the front page. However, when marking, the sam reasoning model could not be automatically recognized according to the prompt points or rectangular boxes, and an error was reported in the terminal: ‘’AttributeError: 'MMDetection' object has no attribute 'value'‘ uTools_1685267491683

zym3122 avatar May 28 '23 09:05 zym3122

This error looks like it happens when the LS backend reads based on the image url, ask if the backend inference and the dataset are in the same device.

JimmyMa99 avatar Jun 01 '23 17:06 JimmyMa99

解决了,但是具体不知道为什么,我重新拉取安装了一下,重新连接并新建后台项目就可以了。PS:(应该是之前没配置好)

zym3122 avatar Jun 21 '23 05:06 zym3122

解决了就好哈哈

JimmyMa99 avatar Jun 22 '23 00:06 JimmyMa99

解决了就好哈哈

我也碰到这个问题了,重装了也不行 image

ccly1996 avatar Aug 01 '23 03:08 ccly1996

传递过来的task[‘data']格式如下

{'id': 210, 'data': {'image': '/data/upload/3/f43a4c65-IMG_20210627_225110.jpg'}, 'meta': {}, 'created_at': '2023-09-05T02:43:47.050202Z', 'updated_at': '2023-09-05T06:46:57.134849Z', 'is_labeled': True, 'overlap': 1, 'inner_id': 1, 'total_annotations': 1, 'cancelled_annotations': 0, 'total_predictions': 0, 'comment_count': 0, 'unresolved_comment_count': 0, 'last_comment_updated_at': None, 'project': 3, 'updated_by': 1, 'file_upload': 211, 'comment_authors': [], 'annotations': [{'id': 4, 'created_username': ' [email protected], 1', 'created_ago': '20\xa0minutes', 'completed_by': 1, 'result': [{'original_width': 4000, 'original_height': 3000, 'image_rotation': 0, 'value': {'x': 28.655660377358487, 'y': 38.05031446540881, 'width': 35.25943396226414, 'height': 33.9622641509434, 'rotation': 0, 'rectanglelabels': ['cat']}, 'id': 'ekRgHmHoPQ', 'from_name': 'RectangleLabels', 'to_name': 'image', 'type': 'rectanglelabels', 'origin': 'manual'}], 'was_cancelled': False, 'ground_truth': False, 'created_at': '2023-09-05T06:46:30.854028Z', 'updated_at': '2023-09-05T06:46:57.089316Z', 'draft_created_at': '2023-09-05T03:10:53.669362Z', 'lead_time': 26.183, 'import_id': None, 'last_action': None, 'task': 210, 'project': 3, 'updated_by': 1, 'parent_prediction': None, 'parent_annotation': None, 'last_created_by': None}], 'predictions': []} kwargs {'login': None, 'password': None, 'context': None}

所以我把self.value调整为 .get("image")

JamesBonddu avatar Sep 05 '23 07:09 JamesBonddu