Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Pylint examples/*.py.
[simgrid.git] / examples / python / actor-migrate / actor-migrate.py
index b78dbfc..9cac4bb 100644 (file)
@@ -3,20 +3,22 @@
 # This program is free software; you can redistribute it and/or modify it
 # under the terms of the license (GNU LGPL) which comes with this package.
 
-# This example demonstrate the actor migrations.
-#
-# The worker actor first move by itself, and then start an execution.
-# During that execution, the monitor migrates the worker, that wakes up on another host.
-# The execution was of the right amount of flops to take exactly 5 seconds on the first host
-# and 5 other seconds on the second one, so it stops after 10 seconds.
-#
-# Then another migration is done by the monitor while the worker is suspended.
-#
-# Note that worker() takes an uncommon set of parameters,
-# and that this is perfectly accepted by create().
+"""
+This example demonstrate the actor migrations.
+
+The worker actor first move by itself, and then start an execution.
+During that execution, the monitor migrates the worker, that wakes up on another host.
+The execution was of the right amount of flops to take exactly 5 seconds on the first host
+and 5 other seconds on the second one, so it stops after 10 seconds.
+
+Then another migration is done by the monitor while the worker is suspended.
+
+Note that worker() takes an uncommon set of parameters,
+and that this is perfectly accepted by create().
+"""
 
-from simgrid import Actor, Engine, Host, this_actor
 import sys
+from simgrid import Actor, Engine, Host, this_actor
 
 
 def worker(first_host, second_host):