use argparse instead of optparse
refs: #3900
Change-Id: I6a883ef5d481aeac4d92e29249e9368d7b1dcf49
diff --git a/ndn/experiments/experiment.py b/ndn/experiments/experiment.py
index f7284a8..a107905 100644
--- a/ndn/experiments/experiment.py
+++ b/ndn/experiments/experiment.py
@@ -35,7 +35,7 @@
self.convergenceTime = args["ctime"]
self.nPings = args["nPings"]
self.strategy = args["strategy"]
- self.pctTraffic = float(args["pctTraffic"])
+ self.pctTraffic = args["pctTraffic"]
# Used to restart pings on the recovered node if any
self.pingedDict = {}
diff --git a/ndn/experiments/pingall_experiment.py b/ndn/experiments/pingall_experiment.py
index 60c8e4e..ba6b570 100644
--- a/ndn/experiments/pingall_experiment.py
+++ b/ndn/experiments/pingall_experiment.py
@@ -31,7 +31,6 @@
Experiment.__init__(self, args)
self.COLLECTION_PERIOD_BUFFER = 10
- self.pctTraffic = float(args["pctTraffic"])
print "Using %f traffic" % self.pctTraffic
def run(self):