コード例 #1
0
    couples = list(itertools.combinations(range(track.aps.shape[0]), 2))
    n_couples = len(couples)

    x_cross = np.zeros((grid.shape[0], n_couples))
    y_cross = np.zeros((grid.shape[0], n_couples))

    dist0 = np.zeros((grid.shape[0], n_couples))
    dist1 = np.zeros((grid.shape[0], n_couples))

    angle0 = np.zeros((grid.shape[0], n_couples))
    angle1 = np.zeros((grid.shape[0], n_couples))

    sdmax = np.zeros((grid.shape[0], n_couples))
    sdmin = np.zeros((grid.shape[0], n_couples))

    remove_sat = fn.crossings_sat(aps_sat, couples, grid.shape[0])
    remove_same_slope = fn.crossings_same_slopes(slopes, couples, grid.shape[0])

    remove_not_valid = remove_sat * remove_same_slope

    i = 0
    for crossing in couples:

        # Calculating cross-section
        x_cross[:, i], y_cross[:, i] = fn.crossings(slopes, y_intercept, crossing)

        # Calculate distance between APs and cross point
        dist0[:, i], dist1[:, i] = fn.crossings_dist(track.aps, crossing, x_cross[:, i], y_cross[:, i])

        # Find angles from both APs
        angle0[:, i] = local_angle_sim[:, crossing[0]]
コード例 #2
0
couples = list(itertools.combinations(range(track.aps.shape[0]), 2))
n_couples = len(couples)

x_cross = np.zeros((track.duration, n_couples))
y_cross = np.zeros((track.duration, n_couples))

dist0 = np.zeros((track.duration, n_couples))
dist1 = np.zeros((track.duration, n_couples))

angle0 = np.zeros((track.duration, n_couples))
angle1 = np.zeros((track.duration, n_couples))

sdmax = np.zeros((track.duration, n_couples))
sdmin = np.zeros((track.duration, n_couples))

remove_sat = fn.crossings_sat(aps_sat, couples, track.duration)
remove_same_slope = fn.crossings_same_slopes(slopes, couples, track.duration)

remove_not_valid = remove_sat * remove_same_slope

i = 0
for crossing in couples:

    # Calculating cross-section
    x_cross[:, i], y_cross[:, i] = fn.crossings(slopes, y_intercept, crossing)

    # Calculate distance between APs and cross point
    dist0[:, i], dist1[:, i] = fn.crossings_dist(track.aps, crossing, x_cross[:, i], y_cross[:, i])

    # Find angles from both APs
    angle0[:, i] = local_angle_sim[:, crossing[0]]
コード例 #3
0
    couples = list(itertools.combinations(range(aps.shape[0]), 2))
    n_couples = len(couples)
    
    x_cross = np.zeros((grid.shape[0], n_couples))
    y_cross = np.zeros((grid.shape[0], n_couples))
    
    dist0 = np.zeros((grid.shape[0], n_couples))
    dist1 = np.zeros((grid.shape[0], n_couples))
    
    angle0 = np.zeros((grid.shape[0], n_couples))
    angle1 = np.zeros((grid.shape[0], n_couples))
    
    sdmax = np.zeros((grid.shape[0], n_couples))
    sdmin = np.zeros((grid.shape[0], n_couples))

    remove_sat = fn.crossings_sat(aps_sat, couples, grid.shape[0])
    remove_same_slope = fn.crossings_same_slopes(slopes, couples, grid.shape[0])

    remove_not_valid = remove_sat * remove_same_slope

    i = 0
    for crossing in couples:
    
        # Calculating cross-section
        x_cross[:, i], y_cross[:, i] = fn.crossings(slopes, y_intercept, crossing)
    
        # Calculate distance between APs and cross point
        dist0[:, i], dist1[:, i] = fn.crossings_dist(aps, crossing, x_cross[:, i], y_cross[:, i])
    
        # Find angles from both APs
        angle0[:, i] = local_angle_sim[:, crossing[0]]