Core code introduction: The code places the four improved model designs of EFEN-YOLOv8 mentioned in the paper, which scholars can easily place in the module of YOLOv8.
How to train?
- Fill the address of yaml in the 'data=r' under the' model.train 'function, for example:' model.train '(data=r'GC-DET.yaml',)
- If you want to train your own dataset, you need to modify the address of the yaml file under ultralytics/cfg/datasets and set up the three paths: train, test, and val.
- you can run it: python myv8test.py
- If you want to obtain the heatmap of a certain structural layer after training the weights, you can execute the yolov8_heatmap.py file. In the if name = = "main ': modify the function : model (r' put your image address here,r' Put your save address here ') 5.After that, you can use the pt file to obtain the verification results and predict some other targets. Run:python test.py
Data set preparation: The data sets are GC10-DET and NEU-DET, which can be easily found and downloaded on the web.
GC10-DET:https://pan.baidu.com/s/1FQ6CAaefgFbefFkYMgrXog?pwd=p1gy key = p1gy NEU-DET: https://pan.baidu.com/s/1Ex4fLiH3v2EqbKVUvr87og?pwd=6ax3 key = 6ax3