namespace geospatial¶
// typedefs typedef ap_uint <32> u32 // structs struct Line struct Node struct Point template <typename DT> struct Rectangle // global variables const uint64_t Q
strtree_contains¶
#include "xf_data_analytics/geospatial/strtree_contains.hpp"
int strtree_contains ( int mode, int x_col, int y_col, std::string point_file, std::string polygon_file, double zone [4], std::vector <std::vector <int>>& results )
strtree_contains geosptial contains (point in polygon) based on strtree
Parameters:
mode | 0: no fpga, 1: index function is accelerated by fpga |
x_col | the column number of x in point csv file |
y_col | the column number of y in point csv file |
point_file | input point csv file |
polygon_file | input polygon file |
results | The id of the first dimension represents the polygon id, and the content represents the point id |
zone | [xmin, xmax, ymin, ymax], Limit the scope of point and polygon. |
Returns:
total size of results
copy2array¶
#include "xf_data_analytics/geospatial/strtree_contains.hpp"
void copy2array ( std::vector <std::vector <int>>& vecs, int* rangevec, int n )
copy2array convert vector to numpy.ndarray
Parameters:
vecs | input vector data |
rangevec | output pointer |
n | output size |