diff --git a/gstlal-inspiral/bin/gstlal_inspiral_add_template_ids b/gstlal-inspiral/bin/gstlal_inspiral_add_template_ids
index aaedaa2d6447a0ca375f2b42d7d5999eef4ad59f..91ce10b2dbad96bb64b5563422f2e1889e0d5b8b 100755
--- a/gstlal-inspiral/bin/gstlal_inspiral_add_template_ids
+++ b/gstlal-inspiral/bin/gstlal_inspiral_add_template_ids
@@ -48,8 +48,8 @@ N = sum(len(lsctables.SnglInspiralTable.get_table(xmldoc)) for fname, xmldoc in
 # N get too close to the number of available IDs to keep the probability of
 # two ID sequences being the same small.
 
-assert N < 50000000, "too many templates:  increase size of draw space"
-ids = sorted(random.sample(xrange(99999999), N))
+assert N < 5000000, "too many templates:  increase size of draw space"
+ids = sorted(random.sample(xrange(9999999), N))
 
 # assign the IDs and write back to disk