text string | label_name string | labels int64 |
|---|---|---|
# Copyright 2018 Amazon.com, Inc. or its affiliates. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License").
# You may not use this file except in compliance with the License.
# A copy of the License is located at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# or in the "license... | Python | 1 |
ature from Hyperbolic space to Euclidean space with curvature of c, taking the origin as a reference point.
Args:
``p`` (``np.ndarray``): The feature matrix. Size :math:`(N, C)`.
``c`` (``int``): Curvature ofHyperbolic space.
"""
sqrt_c = c ** 0.5
p_norm = np.clip(LA.norm(p, axis=-1, kee... | Python | 1 |
for i in start..end {
let v = f(i);
if v < best {
best = v;
result = i;
}
}
(result, best)
} else {
// Try to find minimum faster by recursively checking multiple points.
// Good value: 9.
const NUM... | Rust | 0 |
const u8, msgsz: uint_t, tmout: TMO) -> ER;
pub fn rcv_mbf(mbfid: ID, msg: *mut u8) -> super::ER_UINT;
pub fn prcv_mbf(mbfid: ID, msg: *mut u8) -> super::ER_UINT;
pub fn trcv_mbf(mbfid: ID, msg: *mut u8, tmout: TMO) -> super::ER_UINT;
pub fn ini_mbf(mbfid: ID) -> ER;
pub fn ref_mbf(mbfid: ID, p... | Rust | 0 |
}
/// See [`recursive()`].
pub struct Recursive<'a, I, O, E: Error<I>>(Rc<OnceCell<Box<ParserFn<'a, I, O, E>>>>);
impl<'a, I, O, E: Error<I>> Clone for Recursive<'a, I, O, E> {
fn clone(&self) -> Self {
Self(self.0.clone())
}
}
impl<'a, I, O, E: Error<I>> Parser<I, O> for Recursive<'a, I, O, E> {
... | Rust | 0 |
use super::serial_radix2_fft;
use crate::{domain::utils::parallel_fft, Vec};
use algebra::bls12_381::Bls12_381;
use algebra_core::{test_rng, PairingEngine, UniformRand};
use core::cmp::min;
fn test_consistency<E: PairingEngine, R: Rng>(rng: &mut R, max_coeffs: u32) {
... | Rust | 0 |