Discussion on PCB-AOI Single-Task and Incremental Learning: Path Errors and Dependency Conflicts #344
-
|
What happened: While following the quick start instructions from documentation of ianvs, I encountered a bug. ianvs -f ./examples/pcb-aoi/singletask_learning_bench/benchmarkingjob.yamlI got following exception:- Traceback (most recent call last):
File "/home/aryan/mambaforge/envs/ianvs1/lib/python3.8/site-packages/ianvs-0.1.0-py3.8.egg/core/cmd/benchmarking.py", line 37, in main
job.run()
File "/home/aryan/mambaforge/envs/ianvs1/lib/python3.8/site-packages/ianvs-0.1.0-py3.8.egg/core/cmd/obj/benchmarkingjob.py", line 89, in run
self.test_env.prepare()
File "/home/aryan/mambaforge/envs/ianvs1/lib/python3.8/site-packages/ianvs-0.1.0-py3.8.egg/core/testenvmanager/testenv/testenv.py", line 80, in prepare
raise RuntimeError(f"prepare dataset failed, error: {err}.") from err
RuntimeError: prepare dataset failed, error: not one of train_index/train_data/train_data_info.
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/aryan/mambaforge/envs/ianvs1/bin/ianvs", line 33, in <module>
sys.exit(load_entry_point('ianvs==0.1.0', 'console_scripts', 'ianvs')())
File "/home/aryan/mambaforge/envs/ianvs1/lib/python3.8/site-packages/ianvs-0.1.0-py3.8.egg/core/cmd/benchmarking.py", line 41, in main
raise RuntimeError(f"benchmarkingjob runs failed, error: {err}.") from err
RuntimeError: benchmarkingjob runs failed, error: prepare dataset failed, error: not one of train_index/train_data/train_data_info..What you expected to happen: |
Beta Was this translation helpful? Give feedback.
Replies: 29 comments
-
|
@MooreZheng, any idea why this happened? |
Beta Was this translation helpful? Give feedback.
-
|
Okay, |
Beta Was this translation helpful? Give feedback.
-
|
Also, as per the documentation there should be no fault detection folder, files should be placed directly inside singletask_learning_bench/ |
Beta Was this translation helpful? Give feedback.
-
|
@MooreZheng, which version of tensorflow should I go with. |
Beta Was this translation helpful? Give feedback.
-
|
the current error that I am facing is RuntimeError: benchmarkingjob runs failed, error: testcase(id=84de58c0-cb4e-11ef-9f00-65cc74a7c013) runs failed, error: (paradigm=singletasklearning) pipeline runs failed, error: module(type=basemodel loads class(name=FPN) failed, error: load module(url=./examples/pcb-aoi/singletask_learning_bench/testalgorithms/fpn/basemodel.py)
failed, error: No module named 'FPN_TensorFlow'..
|
Beta Was this translation helpful? Give feedback.
-
|
@FuryMartin do you have any idea about this ? |
Beta Was this translation helpful? Give feedback.
-
This is a custom module in pcb-aoi. Althought I don't know the implemetation details of this module, I remember it can be installed by pip install examples/resources/algorithms/FPN_TensorFlow-0.1-py3-none-any.whl This quick start seems to have some issues, you may also want to check #142 (comment) and #132 (comment) if you encounter new problems. |
Beta Was this translation helpful? Give feedback.
-
Yes, it's a known bug. Would you mind opening a PR to solve this? |
Beta Was this translation helpful? Give feedback.
-
Sure will do that |
Beta Was this translation helpful? Give feedback.
-
This wheel only supports tensorflow version 1.x, and it is only available in Python version <=3.7 |
Beta Was this translation helpful? Give feedback.
-
|
Getting this error when i use python version 3.7 |
Beta Was this translation helpful? Give feedback.
-
|
And on using python version 3.8 getting the following error:- |
Beta Was this translation helpful? Give feedback.
-
You are right, creating a env with python==3.6 will fix this. I once discussed Ianvs's dependency issues in #132 , but no community consensus has been reached yet. |
Beta Was this translation helpful? Give feedback.
-
|
@FuryMartin from here |
Beta Was this translation helpful? Give feedback.
-
this fixed the FPN_Tensorflow version conflicts |
Beta Was this translation helpful? Give feedback.
-
|
tried again, resolved now. Able to run the quickstart from here. +------+-------------------------+----------+--------------------+-----------+--------------------+-------------------------+---------------------+------------------------------------------------------------------------------------------+
| rank | algorithm | f1_score | paradigm | basemodel | basemodel-momentum | basemodel-learning_rate | time | url |
+------+-------------------------+----------+--------------------+-----------+--------------------+-------------------------+---------------------+------------------------------------------------------------------------------------------+
| 1 | fpn_singletask_learning | 0.8527 | singletasklearning | FPN | 0.5 | 0.1 | 2025-01-06 14:30:30 | ./workspace/benchmarkingjob/fpn_singletask_learning/3a76bc25-cc0b-11ef-9f00-65cc74a7c013 |
| 2 | fpn_singletask_learning | 0.844 | singletasklearning | FPN | 0.95 | 0.1 | 2025-01-06 14:25:18 | ./workspace/benchmarkingjob/fpn_singletask_learning/3a76bc24-cc0b-11ef-9f00-65cc74a7c013 |
+------+-------------------------+----------+--------------------+-----------+--------------------+-------------------------+---------------------+------------------------------------------------------------------------------------------+ |
Beta Was this translation helpful? Give feedback.
-
|
Will be working on resolving few issues in the main quickstart guide of ianvs taking this quickstart as reference will add it in the PR here |
Beta Was this translation helpful? Give feedback.
-
|
@FuryMartin, python benchmarking.py -f "./examples/pcb-aoi/singletask_learning_bench/fault detection/benchmarkingjob.yaml"I am getting the following error:- While the other times it is working perfectly |
Beta Was this translation helpful? Give feedback.
-
|
@MooreZheng @hsj576 |
Beta Was this translation helpful? Give feedback.
-
I'm not sure if it is able to work for Python 3.6. If not, you can just comment out JSONMataDataPars in following code ianvs/core/testenvmanager/dataset/dataset.py Lines 21 to 27 in aefdbeb ianvs/core/testenvmanager/dataset/dataset.py Lines 590 to 592 in aefdbeb |
Beta Was this translation helpful? Give feedback.
-
Tried both of these ways, error of |
Beta Was this translation helpful? Give feedback.
-
Sure and it is appreciated. Pls go ahead. |
Beta Was this translation helpful? Give feedback.
-
Ahh, try to comment out and move the import into here? |
Beta Was this translation helpful? Give feedback.
-
|
error got resolved after I downloaded python3.6 compatible onnx version |
Beta Was this translation helpful? Give feedback.
-
|
things are working now. |
Beta Was this translation helpful? Give feedback.
-
|
Conclusion:- |
Beta Was this translation helpful? Give feedback.
-
|
I unpacked the FPN_TensorFlow-0.1-py3-none-any.whl wheel and found out it currently has these requirements:- -> Reasons of compatibility issues with python versions >3.6 are:-
Hence, there is a need to migrate the FPN_TensorFlow-0.1-py3-none-any.whl from tensorflow version 1.x to tensorflow version 2.x. This in itself is a big task. |
Beta Was this translation helpful? Give feedback.
-
|
While trying to run Traceback (most recent call last):
File "/home/aryan/mambaforge/envs/ianvs3.6/lib/python3.6/site-packages/ianvs-0.1.0-py3.6.egg/core/cmd/benchmarking.py", line 37, in main
File "/home/aryan/mambaforge/envs/ianvs3.6/lib/python3.6/site-packages/ianvs-0.1.0-py3.6.egg/core/cmd/obj/benchmarkingjob.py", line 94, in run
File "/home/aryan/mambaforge/envs/ianvs3.6/lib/python3.6/site-packages/ianvs-0.1.0-py3.6.egg/core/testcasecontroller/testcasecontroller.py", line 56, in run_testcases
RuntimeError: testcase(id=10674f78-d34c-11ef-857c-01b2a5047042) runs failed, error: (paradigm=incrementallearning) pipeline runs failed, error: 'NoneType' object has no attribute 'lstrip'
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/aryan/mambaforge/envs/ianvs3.6/bin/ianvs", line 33, in <module>
sys.exit(load_entry_point('ianvs==0.1.0', 'console_scripts', 'ianvs')())
File "/home/aryan/mambaforge/envs/ianvs3.6/lib/python3.6/site-packages/ianvs-0.1.0-py3.6.egg/core/cmd/benchmarking.py", line 41, in main
RuntimeError: benchmarkingjob runs failed, error: testcase(id=10674f78-d34c-11ef-857c-01b2a5047042) runs failed, error: (paradigm=incrementallearning) pipeline runs failed, error: 'NoneType' object has no attribute 'lstrip'.@FuryMartin, do you have any idea about this? |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
This issue is also solved by #171 To sum up, the PCB-AoI example has two recognized issues so far:
Python version (ongoing)
It starts from #68 . The PCB-AoI example only works on Python 3.6, thus has compatibility issue for Python 3.7+ versions, see discussion in #209. We will close #68 #209 after the PCB-AoI example is fixed properly. See also recent update from #329
Third-party wheels (completed)
The compatibility issue for PCB-AoI is also related to the requirements of third-party wheels. See a comprehensive analysis conducted in #132 #152 and #170. The issue #170 is solved by PR #171 and reported in #182