{"action":"created","issue":{"url":"https://api.github.com/repos/strands-project/data_compression/issues/59","labels_url":"https://api.github.com/repos/strands-project/data_compression/issues/59/labels{/name}","comments_url":"https://api.github.com/repos/strands-project/data_compression/issues/59/comments","events_url":"https://api.github.com/repos/strands-project/data_compression/issues/59/events","html_url":"https://github.com/strands-project/data_compression/issues/59","id":53874711,"number":59,"title":"specifing the date when replaying a recorded video","user":{"login":"vonovak","id":1566403,"avatar_url":"https://avatars.githubusercontent.com/u/1566403?v=3","gravatar_id":"","url":"https://api.github.com/users/vonovak","html_url":"https://github.com/vonovak","followers_url":"https://api.github.com/users/vonovak/followers","following_url":"https://api.github.com/users/vonovak/following{/other_user}","gists_url":"https://api.github.com/users/vonovak/gists{/gist_id}","starred_url":"https://api.github.com/users/vonovak/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vonovak/subscriptions","organizations_url":"https://api.github.com/users/vonovak/orgs","repos_url":"https://api.github.com/users/vonovak/repos","events_url":"https://api.github.com/users/vonovak/events{/privacy}","received_events_url":"https://api.github.com/users/vonovak/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-01-09T14:47:27Z","updated_at":"2015-01-09T15:04:40Z","closed_at":null,"body":"When using the `mongodb_play.py` utility to replay the rgb and depth topics, is it possible to specify date (datetime) from which the playback should start?\r\nThanks"},"comment":{"url":"https://api.github.com/repos/strands-project/data_compression/issues/comments/69345346","html_url":"https://github.com/strands-project/data_compression/issues/59#issuecomment-69345346","issue_url":"https://api.github.com/repos/strands-project/data_compression/issues/59","id":69345346,"user":{"login":"nilsbore","id":4670159,"avatar_url":"https://avatars.githubusercontent.com/u/4670159?v=3","gravatar_id":"","url":"https://api.github.com/users/nilsbore","html_url":"https://github.com/nilsbore","followers_url":"https://api.github.com/users/nilsbore/followers","following_url":"https://api.github.com/users/nilsbore/following{/other_user}","gists_url":"https://api.github.com/users/nilsbore/gists{/gist_id}","starred_url":"https://api.github.com/users/nilsbore/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nilsbore/subscriptions","organizations_url":"https://api.github.com/users/nilsbore/orgs","repos_url":"https://api.github.com/users/nilsbore/repos","events_url":"https://api.github.com/users/nilsbore/events{/privacy}","received_events_url":"https://api.github.com/users/nilsbore/received_events","type":"User","site_admin":false},"created_at":"2015-01-09T15:04:40Z","updated_at":"2015-01-09T15:04:40Z","body":"That is not supported at the moment, AFAIK. @hawesie has done something similar before though:\r\n``` python\r\ndef mkdatetime(date_string):\r\n    return datetime.strptime(date_string, '%d/%m/%y %H:%M')\r\n\r\nif __name__ == \"__main__\":\r\n    rospy.init_node(\"schedule_replay\")\r\n\r\n    parser = argparse.ArgumentParser(description='Replays saved scheduling problems from mongodb_store.')\r\n\r\n    parser.add_argument('start', metavar='S', type=mkdatetime, nargs='?', default=datetime.utcfromtimestamp(0),\r\n                   help='start datetime of query, defaults to no start. Formatted \"d/m/y H:M\" e.g. \"06/07/14 06:38\"')\r\n\r\n    parser.add_argument('end', metavar='E', type=mkdatetime, nargs='?', default=datetime.utcnow(),\r\n                   help='end datetime of query, defaults to now. Formatted \"d/m/y H:M\" e.g. \"06/07/14 06:38\"')\r\n\r\n\r\n    args = parser.parse_args()\r\n\r\n\r\n\r\n    msg_store = MessageStoreProxy(collection='scheduling_problems')\r\n    meta_query = {}\r\n    meta_query[\"inserted_at\"] = {\"$gte\": args.start, \"$lte\" : args.end} \r\n\r\n    scheduling_problems = msg_store.query(StringPairList._type, meta_query=meta_query)\r\n```\r\nfrom https://github.com/strands-project/strands_executive/blob/hydro-devel/scheduler/scripts/replay_scheduling_problems.py\r\nBut you need to use the command line args to set these: https://github.com/strands-project/mongodb_store/blob/hydro-devel/mongodb_store/scripts/mongodb_play.py#L284\r\n\r\nHope this helps."}}