本文整理汇总了Python中Warehouse.Warehouse.setiniworkerposi方法的典型用法代码示例。如果您正苦于以下问题:Python Warehouse.setiniworkerposi方法的具体用法?Python Warehouse.setiniworkerposi怎么用?Python Warehouse.setiniworkerposi使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Warehouse.Warehouse
的用法示例。
在下文中一共展示了Warehouse.setiniworkerposi方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: search
# 需要导入模块: from Warehouse import Warehouse [as 别名]
# 或者: from Warehouse.Warehouse import setiniworkerposi [as 别名]
sys.exit(2)
else:
try:
inputhandler=Inputhandler()
MAP=inputhandler.filetostr(sys.argv[1])
except IOError:
sys.stderr.write("ERROR: Cannot read inputfile\n")
sys.exit(1)
# this section of inputing files is referred from the codes provided in NLP course, Columbia University, COMS 4705 2013
inputhandler=Inputhandler()
warehouse=Warehouse(MAP)
warehouse.setiniworkerposi()
print ("The configuration of the input:")
warehouse.show()
root=node(warehouse) # load to the tree
instr=""
solution=""
while(1):
print("\nplease choose the searching method:\nb :BFS\nd :DFS\nu :UCS")
print("g_1 :Greedy best first search (heuristic 1)")
print("g_2 :Greedy best first search (heuristic 2)")
print("a_1 :A* search (heuristic 1)")
print("a_2 :A* search (heuristic 2)")
print("Others :quit")