Multiply the cpu times in this CPU::Usage instance with +scalar+.
556234
def *(scalar)
      scalar = scalar.to_f
      self.class.new(*(
        [
          usage,
          processor_id,
        ] +
        values_at(2..-3).map { |x| x * scalar } +
        [
          start_at,
          stop_at,
        ])
      )
    end
924738
def mul(a, b):
  
  def multiply(a, b):
    """Multiplication"""
    return a * b
  return op_with_scalar_cast(a, b, multiply)
394792
def *(other)
      case other
      when Mat4    then mul_mat4(other)
      when Mat3    then mul_mat3(other)
      when Vec3    then mul_vec3(other)
      when Vec4    then mul_vec4(other)
      when Numeric then mul_scalar(other)
      else raise ArgumentError, "Don't know how to multiply Mat4 with object: #{other.inspect}"
      end
    end
694733
public MachineTime<U> multipliedBy(long factor) {

        if (factor == 1) {
            return this;
        } else if (factor == 0) {
            if (this.scale == POSIX) {
                return cast(POSIX_ZERO);
            } else {
                return cast(UTC_ZERO);
            }
        }

        BigDecimal value =
            this.toBigDecimal().multiply(BigDecimal.valueOf(factor));
        MachineTime<?> mt;

        if (this.scale == POSIX) {
            mt = MachineTime.ofPosixSeconds(value);
        } else {
            mt = MachineTime.ofSISeconds(value);
        }

        return cast(mt);

    }
1186247
def rescale_around1(self, times):
        
        if self._unit == self._UNIT_STEP:
            return times, 'step' # nothing to do

        m = np.mean(times)
        mult = 1.0
        cur_unit = self._unit

        # numbers are too small. Making them larger and reducing the unit:
        if (m < 0.001):
            while mult*m < 0.001 and cur_unit >= 0:
                mult *= 1000
                cur_unit -= 1
            return mult*times, self._unit_names[cur_unit]

        # numbers are too large. Making them smaller and increasing the unit:
        if (m > 1000):
            while mult*m > 1000 and cur_unit <= 5:
                mult /= 1000
                cur_unit += 1
            return mult*times, self._unit_names[cur_unit]

        # nothing to do
        return times, self._unit
1062815
def _multiply(self, x1, x2, out):
        """"""
        for spc, xp, yp, outp in zip(self.spaces, x1.parts, x2.parts,
                                     out.parts):
            spc._multiply(xp, yp, outp)
203757
def multiply(x1, x2, output_shape=None, name=None):
  
  if not isinstance(x2, Tensor):
    return ScalarMultiplyOperation(x1, x2).outputs[0]
  with tf.name_scope(name, default_name="mul"):
    x1, x2 = binary_arguments_to_tensors(x1, x2)
    return einsum(
        [x1, x2],
        output_shape=_infer_binary_broadcast_shape(
            x1.shape, x2.shape, output_shape))
95343
public static void multiply( GrayU8 input , double value , GrayU8 output ) {

		output.reshape(input.width,input.height);

		int columns = input.width;
		if(BoofConcurrency.USE_CONCURRENT ) {
			ImplPixelMath_MT.multiplyU_A(input.data,input.startIndex,input.stride,value , 
					output.data,output.startIndex,output.stride,
					input.height,columns);
		} else {
			ImplPixelMath.multiplyU_A(input.data,input.startIndex,input.stride,value , 
					output.data,output.startIndex,output.stride,
					input.height,columns);
		}
	}
130346
function(cpu) {
        if (!isNaN(cpu)) {
            var cpuHistory = this.get('cpu');
            if (!cpuHistory) {
                cpuHistory = [];
                this.set('cpu', cpuHistory);
            }

            cpuHistory.push(cpu);
            while (cpuHistory.length > this._statHistory) {
                cpuHistory.shift();
            }

            var avg = 0;
            cpuHistory.filter(function(f) {
                return f !== null;
            }).forEach(function(f) {
                avg += f;
            });
            avg /= cpuHistory.length;
            this.set({
                avgCpu: Math.round(avg)
            });
        }
    }
1354952
def on_cpu_change(self, cpu, add):
        
        if not isinstance(cpu, baseinteger):
            raise TypeError("cpu can only be an instance of type baseinteger")
        if not isinstance(add, bool):
            raise TypeError("add can only be an instance of type bool")
        self._call("onCPUChange",
                     in_p=[cpu, add])
163921
def _compute(self):
        
        r = self
        for func, args, kwargs in self._todo:
            r = func(self)(*args, **kwargs)
        return r
574174
def benchmark(times = 1, &block)
      elapsed = (1..times).collect do
        GC.start
        ::Benchmark.realtime(&block) * times
      end

      Result.new(elapsed)
    end
570711
private long cpuTime(Thread thr) {
        ThreadMXBean mxBean = ManagementFactory.getThreadMXBean();
        if (mxBean.isThreadCpuTimeSupported()) {
            try {
                return mxBean.getThreadCpuTime(thr.getId());
            } catch (UnsupportedOperationException e) {
            }
        }
        return 0;
    }
124477
function updateCpu (cpu, next) {
  if (cpu !== null) {
    getRealUptime(function (err, uptime) {
      if (err) return next(err)
      cpu.uptime = uptime
      next(null, cpu)
    })
    return
  }

  parallel([
    getClockAndPageSize,
    getRealUptime
  ], function (err, data) {
    if (err) return next(err)

    cpu = {
      clockTick: data[0].clockTick,
      pageSize: data[0].pageSize,
      uptime: data[1]
    }

    next(null, cpu)
  })
}
1307411
def +(other)
      if Duration === other
        parts = @parts.dup
        other.parts.each do |(key, value)|
          parts[key] += value
        end
        Duration.new(value + other.value, parts)
      else
        seconds = @parts[:seconds] + other
        Duration.new(value + other, @parts.merge(seconds: seconds))
      end
    end
570055
def cpu
      cpus = []
      procfs_file("stat") do |file|
        file.read.scan(CPU_DATA) do |i, user, nice, system, idle|
          cpus << Cpu.new(i.to_i, user.to_i, system.to_i, nice.to_i, idle.to_i)
        end
      end
      cpus
    end
169518
function() {
        if (process.platform !== 'win32') {
            return;
        }

        this._cpuConsole = child_process.spawn('typeperf', ['\\Processor(_Total)\\% Processor Time']);
        this._cpuConsole.stdout.on('data', _.bind(function(stdout) {

            stdout = stdout.toString();
            if (stdout && stdout.indexOf(',') === 0) {
                var cpu = parseFloat(stdout.substr(2, stdout.length - 3));
                this._cpuFrame(cpu);
            }
        }, this));
    }