MobileAgent icon indicating copy to clipboard operation
MobileAgent copied to clipboard

mac m3运行后报错,感觉是TensorFlow=2.9.0不支持m3,求指导

Open shenxingqi opened this issue 1 year ago • 5 comments

image

The TensorFlow library was compiled to use AVX instructions, but these aren't available on your machine.

shenxingqi avatar Nov 03 '24 14:11 shenxingqi

TensorFlow只用于OCR,可以自行替换模型

junyangwang0410 avatar Nov 04 '24 08:11 junyangwang0410

怎么替换模型呀,是把OC R换成其他的吗

kx-kexi avatar Feb 25 '25 06:02 kx-kexi

https://github.com/X-PLUG/MobileAgent/blob/main/Mobile-Agent-v2/MobileAgent/text_localization.py

格式是 text -> List ["text1", "text2", ..., "textn"], coordinate -> List [[x1, y1, x2, y2], [x1, y1, x2, y2], ..., [x1, y1, x2, y2]]

junyangwang0410 avatar Feb 25 '25 07:02 junyangwang0410

https://github.com/X-PLUG/MobileAgent/blob/main/Mobile-Agent-v2/MobileAgent/text_localization.py

格式是 text -> List ["text1", "text2", ..., "textn"], coordinate -> List [[x1, y1, x2, y2], [x1, y1, x2, y2], ..., [x1, y1, x2, y2]]

啥意思呀,没看懂

kx-kexi avatar Feb 25 '25 07:02 kx-kexi

https://github.com/X-PLUG/MobileAgent/blob/main/Mobile-Agent-v2/MobileAgent/text_localization.py 格式是 text -> List ["text1", "text2", ..., "textn"], coordinate -> List [[x1, y1, x2, y2], [x1, y1, x2, y2], ..., [x1, y1, x2, y2]]

啥意思呀,没看懂

修改MobileAgent/text_localization.py文件,保持这一行代码的返回格式就可以,text_data的格式是,List,其中每个元素都是一个文本,["text1", "text2", ..., "textn"], coordinate的格式是List,每个元素都是一个4元组,代表对应index下的文本的bbox,用左上角坐标和右下角坐标代替,[[x1, y1, x2, y2], [x1, y1, x2, y2], ..., [x1, y1, x2, y2]]。

你可以修改这个文件里的ocr模型和调用方式,只需要保持返回值不变,就仍然可以运行项目

junyangwang0410 avatar Feb 25 '25 07:02 junyangwang0410