2017-02-16 5 views
0
sumoBinary = "/usr/bin/sumo-gui" 
sumoCmd = [sumoBinary, "-c", "map.sumo.cfg"] 
import traci 
traci.start(sumoCmd) 

私が使用している場合、私は次のエラーを取得するtraci.start(sumoCmd)トレイシーモジュール - 問題のランニングtraci.start(sumoCmd)

AtributeError: 'module' object has no attribute 'start'

私はトレイシーモジュールを検索する場合ので、論理的であると

['FatalTraCIError', 'Message', 'Storage', 'SubscriptionResults', 'TraCIException', '_DEBUG', '_RESULTS', '_STEPS2TIME', '_TIME2STEPS', '__builtins__', '__doc__', '__file__', '__name__', '__package__', '__path__', '_beginMessage', '_checkResult', '_connections', '_embedded', '_message', '_modules', '_readSubscription', '_recvExact', '_sendByteCmd', '_sendDoubleCmd', '_sendExact', '_sendIntCmd', '_sendReadOneStringCmd', '_sendStringCmd', '_subscribe', '_subscribeContext', 'areal', 'close', 'constants', 'edge', 'getParameterAccessors', 'getVersion', 'gui', 'inductionloop', 'init', 'isEmbedded', 'junction', 'lane', 'multientryexit', 'person', 'poi', 'polygon', 'print_function', 'route', 'simulation', 'simulationStep', 'socket', 'struct', 'switch', 'time', 'trafficlights', 'vehicle', 'vehicletype'] 

この機能がうまく使用されていると私はそれはトレイシーモジュールに含まれていたと思った:まったくスタート機能がない分析するには、dirコマンドを使用します。

それが見られるように:http://www.sumo.dlr.de/wiki/TraCI/Interfacing_TraCI_from_Python

を誰もが、私はそれを見つけることができますどのように説明できますか?ありがとう

私はsumo-0.25.0を使用していますので、traci.startはそれ以降のバージョンに含まれていましたか?

答えて

1

sumo traciモジュールを新しいもの(0.29)に更新しました。

残念ながら、sumo-0.25 traciモジュールにはtraci.start(sumoCmd)関数がありません

関連する問題