def loop_for(name, seconds, options={}, &blk)
      end_at = Time.now + seconds
      if options[:warmup]
        options[:warmup].times do |i|
          #puts "Warming up... #{i}"
          yield i
        end
      end
      i = 0
      while Time.now < end_at
        time_i(i, name, options, &blk)
        i += 1
      end
    end
def loop_for(name, seconds, options={}, &blk)
      end_at = Time.now + seconds
      if options[:warmup]
        options[:warmup].times do |i|
          #puts "Warming up... #{i}"
          yield i
        end
      end
      i = 0
      while Time.now < end_at
        time_i(i, name, options, &blk)
        i += 1
      end
    end
will loop for number of seconds