本文整理汇总了Python中tactic_client_lib.TacticServerStub.get_snapshot方法的典型用法代码示例。如果您正苦于以下问题:Python TacticServerStub.get_snapshot方法的具体用法?Python TacticServerStub.get_snapshot怎么用?Python TacticServerStub.get_snapshot使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类tactic_client_lib.TacticServerStub
的用法示例。
在下文中一共展示了TacticServerStub.get_snapshot方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: _test_get_submission
# 需要导入模块: from tactic_client_lib import TacticServerStub [as 别名]
# 或者: from tactic_client_lib.TacticServerStub import get_snapshot [as 别名]
def _test_get_submission(self):
server = TacticServerStub()
server.set_project("sample3d")
# choose some arbitrary bin
bin_id = 4
filters = []
filters.append( ['bin_id', bin_id] )
connectors = server.query("prod/submission_in_bin", filters)
# get all of the submissions from the bin
submission_ids = [x.get('submission_id') for x in connectors]
filters = [ ['id', submission_ids] ]
submissions = server.query("prod/submission", filters)
# get all of the snapshots from the submissions
for submission in submissions:
search_key = submission.get('__search_key__')
print "-"*20
snapshot = server.get_snapshot(search_key, include_paths=True)
paths = snapshot.get('__paths__')
for path in paths:
print path