Closed sjh30 closed 1 month ago
Can you confirm the error for the newest release as well? As you now try to use the python client in MATLAB, you don't need to use an older version like you might have to with outdated traci4matlab.
I download the newest version sumo1.20.But the erros is still the same :Did not identify the class 'py. Traci. _trafficlight. TrafficLightDomain' methods, properties, or fields' Phase '.
I check the py.traci.trafficlight , the function Phase and Logic are not in it. And Phase is class in trafficlight.py .I dont know whether this is the reason why i cant use the function?
In either case Phase should be available. In newer releases the class is declared in sumolib.net but imported into _trafficlight.py.
But i failed to use the function.I think i have to turn to other solutions. Thank you so much for your help.You really help me a lot!
I am trying to use traci function by python in matlab. Here is my code:
And i met an error when i use the function:
phase1=traci.trafficlight.Phase(py.int(30), "GGGGGrrrrrGGGGGrrrrr", py.int(0), py.int(0), py.list({1}));
Here is the error message: 未识别类 'py.traci._trafficlight.TrafficLightDomain' 的方法、属性或字段 'Phase'。 Which means Did not identify the class 'py. Traci. _trafficlight. TrafficLightDomain' methods, properties, or fields' Phase '.
Can anyone tell me how to solve this problem
**SUMO-version:1.1
**operating system:windows11