Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 912 for float1 (0.14 sec)

  1. src/reflect/value.go

    }
    
    // CanFloat reports whether [Value.Float] can be used without panicking.
    func (v Value) CanFloat() bool {
    	switch v.kind() {
    	case Float32, Float64:
    		return true
    	default:
    		return false
    	}
    }
    
    // Float returns v's underlying value, as a float64.
    // It panics if v's Kind is not [Float32] or [Float64]
    func (v Value) Float() float64 {
    	k := v.kind()
    	switch k {
    	case Float32:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 21:17:41 UTC 2024
    - 119.9K bytes
    - Viewed (0)
  2. src/database/sql/convert_test.go

    		{s: 2, d: &scanbool, wanterr: `sql/driver: couldn't convert 2 into type bool`},
    
    		// Floats
    		{s: float64(1.5), d: &scanf64, wantf64: float64(1.5)},
    		{s: int64(1), d: &scanf64, wantf64: float64(1)},
    		{s: float64(1.5), d: &scanf32, wantf32: float32(1.5)},
    		{s: "1.5", d: &scanf32, wantf32: float32(1.5)},
    		{s: "1.5", d: &scanf64, wantf64: float64(1.5)},
    
    		// Pointers
    		{s: any(nil), d: &scanptr, wantnil: true},
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Apr 10 20:23:22 UTC 2024
    - 17K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/lite/python/tf_tfl_flatbuffer_helpers.cc

        "'h_scale' type: 'float'} attr : { name: 'max_classes_per_detection' "
        "type: 'int'} attr : { name: 'max_detections' type: 'int'} attr : { "
        "name: 'nms_iou_threshold' type: 'float'} attr : { name: "
        "'nms_score_threshold' type: 'float'} attr : { name: 'num_classes' type: "
        "'int'} attr : { name: 'w_scale' type: 'float'} attr : { name: 'x_scale' "
        "type: 'float'} attr : { name: 'y_scale' type: 'float'} attr { name: "
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Sun May 12 12:39:37 UTC 2024
    - 17.3K bytes
    - Viewed (0)
  4. src/math/rand/v2/regress_test.go

    	float32(0.45059562),  // Float32()
    	float32(0.86597633),  // Float32()
    	float32(0.8954844),   // Float32()
    	float32(0.090798736), // Float32()
    	float32(0.46218646),  // Float32()
    	float32(0.5955118),   // Float32()
    	float32(0.08985227),  // Float32()
    	float32(0.19820237),  // Float32()
    	float32(0.7443699),   // Float32()
    	float32(0.56461),     // Float32()
    
    	float64(0.6764556596678251),  // Float64()
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 07 18:03:11 UTC 2024
    - 20.3K bytes
    - Viewed (0)
  5. src/go/types/builtins_test.go

    	{"complex", `_ = complex(1, 0)`, `invalid type`}, // constant
    	{"complex", `var re float32; _ = complex(re, 1.0)`, `func(float32, float32) complex64`},
    	{"complex", `var im float64; _ = complex(1, im)`, `func(float64, float64) complex128`},
    	{"complex", `type F32 float32; var re, im F32; _ = complex(re, im)`, `func(p.F32, p.F32) complex64`},
    	{"complex", `type F64 float64; var re, im F64; _ = complex(re, im)`, `func(p.F64, p.F64) complex128`},
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Apr 03 18:48:38 UTC 2024
    - 10.9K bytes
    - Viewed (0)
  6. src/math/big/float_test.go

    		opname        rune
    		op            func(z, x, y *Float) *Float
    	}{
    		{0, 0, 0, 0, '+', (*Float).Add},
    		{0, 1, 2, 3, '+', (*Float).Add},
    		{1, 2, 0, 2, '+', (*Float).Add},
    		{2, 0, 1, 1, '+', (*Float).Add},
    
    		{0, 0, 0, 0, '-', (*Float).Sub},
    		{0, 1, 2, -1, '-', (*Float).Sub},
    		{1, 2, 0, 2, '-', (*Float).Sub},
    		{2, 0, 1, -1, '-', (*Float).Sub},
    
    		{0, 0, 0, 0, '*', (*Float).Mul},
    		{0, 1, 2, 2, '*', (*Float).Mul},
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 11 20:22:45 UTC 2024
    - 51.9K bytes
    - Viewed (0)
  7. src/math/big/floatmarsh.go

    // to the decoded value.
    func (z *Float) GobDecode(buf []byte) error {
    	if len(buf) == 0 {
    		// Other side sent a nil or default value.
    		*z = Float{}
    		return nil
    	}
    	if len(buf) < 6 {
    		return errors.New("Float.GobDecode: buffer too small")
    	}
    
    	if buf[0] != floatGobVersion {
    		return fmt.Errorf("Float.GobDecode: encoding version %d not supported", buf[0])
    	}
    
    	oldPrec := z.prec
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 13 21:31:58 UTC 2024
    - 3.6K bytes
    - Viewed (0)
  8. src/fmt/fmt_test.go

    	// The sharp flag has no effect for binary float format.
    	{"%#b", 1.0, "4503599627370496p-52"},
    	// Precision has no effect for binary float format.
    	{"%.4b", float32(1.0), "8388608p-23"},
    	{"%.4b", -1.0, "-4503599627370496p-52"},
    	// Test correct f.intbuf boundary checks.
    	{"%.68f", 1.0, zeroFill("1.", 68, "")},
    	{"%.68f", -1.0, zeroFill("-1.", 68, "")},
    	// float infinites and NaNs
    	{"%f", posInf, "+Inf"},
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 04 17:31:55 UTC 2024
    - 58.6K bytes
    - Viewed (0)
  9. src/math/rand/v2/rand_test.go

    func initNorm() (testKn []uint32, testWn, testFn []float32) {
    	const m1 = 1 << 31
    	var (
    		dn float64 = rn
    		tn         = dn
    		vn float64 = 9.91256303526217e-3
    	)
    
    	testKn = make([]uint32, 128)
    	testWn = make([]float32, 128)
    	testFn = make([]float32, 128)
    
    	q := vn / math.Exp(-0.5*dn*dn)
    	testKn[0] = uint32((dn / q) * m1)
    	testKn[1] = 0
    	testWn[0] = float32(q / m1)
    	testWn[127] = float32(dn / m1)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 18:42:28 UTC 2024
    - 17.4K bytes
    - Viewed (0)
  10. src/expvar/expvar.go

    }
    
    func (v *Int) Set(value int64) {
    	v.i.Store(value)
    }
    
    // Float is a 64-bit float variable that satisfies the [Var] interface.
    type Float struct {
    	f atomic.Uint64
    }
    
    func (v *Float) Value() float64 {
    	return math.Float64frombits(v.f.Load())
    }
    
    func (v *Float) String() string {
    	return string(v.appendJSON(nil))
    }
    
    func (v *Float) appendJSON(b []byte) []byte {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Apr 26 21:32:11 UTC 2024
    - 9.1K bytes
    - Viewed (0)
Back to top