How to use the pyodm.api.Task function in pyodm

To help you get started, we’ve selected a few pyodm examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github OpenDroneMap / PyODM / pyodm / api.py View on Github external
def handle_task_new_response(self, result):
        if isinstance(result, dict) and 'uuid' in result:
            return Task(self, result['uuid'])
        elif isinstance(result, dict) and 'error' in result:
            raise NodeResponseError(result['error'])
        else:
            raise NodeServerError('Invalid response: ' + str(result))
github OpenDroneMap / PyODM / pyodm / api.py View on Github external
def get_task(self, uuid):
        """Helper method to initialize a task from an existing UUID

        >>> n = Node("localhost", 3000)
        >>> t = n.get_task('00000000-0000-0000-0000-000000000000')
        >>> t.__class__
        

        Args:
            uuid: Unique identifier of the task
        """
        return Task(self, uuid)