I use the GEE Python client to perform image fusion. There are two nested for loops, in the end, I use the ee.batch.export.toDrive method to create the task. However, each task consumes a significant amount of time and user memory. So I want to submit the task without automatic execution to control the running tasks number. I tried the task.state = 'READY', but I could not find the task, there was also no 'run' button. How can I solve this problem?

task = ee.batch.Export.image.toDrive(
description= export_description,
folder = folder.getInfo(),
region = ee.Image(prediction.get(0)).geometry(),
scale = 30)\

task.state = 'READY'

1 Answer 1


It's not quite clear, but I think what you're asking is how to start a task. You do that with task.start().

From the built-in python documentation:

>>> import ee
>>> help(ee.batch.Task)

class Task(builtins.object)
 |  Task(task_id, task_type, state, config=None, name=None)
 |  ...
 |  start(self)
 |      Starts the task. No-op for started tasks.
  • Thanks for your reply. Are you suggesting to use ee.batch.Task to create tasks instead of using ee.batch.export.toDrive() to create tasks? Mar 23, 2023 at 12:22
  • Not exactly. ee.batch.Export.image.toDrive() returns a Task, that you have to start(). The docs for ee.batch.Export.image.toDrive() say: "Returns: An unstarted Task that exports the table" Mar 24, 2023 at 10:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.