日本熟妇hd丰满老熟妇,中文字幕一区二区三区在线不卡 ,亚洲成片在线观看,免费女同在线一区二区

對(duì)一條軌跡重采樣。

語(yǔ)法

trajectory ST_Resample(trajectory traj, config);

參數(shù)

參數(shù)名稱

描述

traj

被重采樣的軌跡對(duì)象。

config

重采樣軌跡的規(guī)則。格式{"規(guī)則":"取值"}。

目前包含以下可選規(guī)則,每次調(diào)用此函數(shù)時(shí),僅可選擇一個(gè)規(guī)則:

規(guī)則名稱

參數(shù)類型

說(shuō)明

add_point.distance_lesser

浮點(diǎn)數(shù)

在每條軌跡線上均勻添加點(diǎn),使每一段之間的距離均小于參數(shù)。

add_point.period_lesser

可以轉(zhuǎn)化為Interval類型的字符串

在每條軌跡線上均勻添加點(diǎn),使每一段的時(shí)長(zhǎng)均小于參數(shù)。

drop_point.distance_lesser

浮點(diǎn)數(shù)

如果相鄰多段軌跡線段上所有的點(diǎn)到起點(diǎn)的長(zhǎng)度,均小于此參數(shù)給定的空間長(zhǎng)度時(shí),將其合并(僅保留起點(diǎn)和終點(diǎn))。

drop_point.period_lesser

可以轉(zhuǎn)化為Interval類型的字符串

當(dāng)相鄰多段軌跡線段的時(shí)間長(zhǎng)度之和小于給定的時(shí)間長(zhǎng)度時(shí),將其合并(僅保留起點(diǎn)和終點(diǎn))。

描述

根據(jù)提前設(shè)定的規(guī)則對(duì)軌跡對(duì)象重采樣,返回重采樣后的軌跡。

示例

With traj As
(
  select '{"trajectory":{"version":1,"type":"STPOINT","leafcount":5,"start_time":"2000-01-01 00:00:00","end_time":"2000-01-05 00:00:00","spatial":"LINESTRING(1 1,10 10,11 11,13 13,15 15)","timeline":["2000-01-01 00:00:00","2000-01-02 00:00:00","2000-01-03 00:00:00","2000-01-04 00:00:00","2000-01-05 00:00:00"]}}'::trajectory a
)
SELECT ST_Resample(a, '{"add_point.distance_lesser":3}') from traj;
                                                                                                                                                                                                              st_resample                                                                                                                                                                                                               
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 {"trajectory":{"version":1,"type":"STPOINT","leafcount":9,"start_time":"2000-01-01 00:00:00","end_time":"2000-01-05 00:00:00","spatial":"LINESTRING(1 1,2.8 2.8,4.6 4.6,6.4 6.4,8.2 8.2,10 10,11 11,13 13,15 15)","timeline":["2000-01-01 00:00:00","2000-01-01 04:48:00","2000-01-01 09:36:00","2000-01-01 14:24:00","2000-01-01 19:12:00","2000-01-02 00:00:00","2000-01-03 00:00:00","2000-01-04 00:00:00","2000-01-05 00:00:00"]}}
(1 row)

With traj As
(
  select '{"trajectory":{"version":1,"type":"STPOINT","leafcount":5,"start_time":"2000-01-01 00:00:00","end_time":"2000-01-05 00:00:00","spatial":"LINESTRING(1 1,10 10,11 11,13 13,15 15)","timeline":["2000-01-01 00:00:00","2000-01-02 00:00:00","2000-01-03 00:00:00","2000-01-04 00:00:00","2000-01-05 00:00:00"]}}'::trajectory a
)
SELECT ST_Resample(a, '{"add_point.period_lesser":"0.5 day"}') from traj;
                                                                                                                                                                                                             st_resample                                                                                                                                                                                                              
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 {"trajectory":{"version":1,"type":"STPOINT","leafcount":9,"start_time":"2000-01-01 00:00:00","end_time":"2000-01-05 00:00:00","spatial":"LINESTRING(1 1,5.5 5.5,10 10,10.5 10.5,11 11,12 12,13 13,14 14,15 15)","timeline":["2000-01-01 00:00:00","2000-01-01 12:00:00","2000-01-02 00:00:00","2000-01-02 12:00:00","2000-01-03 00:00:00","2000-01-03 12:00:00","2000-01-04 00:00:00","2000-01-04 12:00:00","2000-01-05 00:00:00"]}}
(1 row)

With traj As
(
  select '{"trajectory":{"version":1,"type":"STPOINT","leafcount":5,"start_time":"2000-01-01 00:00:00","end_time":"2000-01-05 00:00:00","spatial":"LINESTRING(1 1,10 10,11 11,13 13,15 15)","timeline":["2000-01-01 00:00:00","2000-01-02 00:00:00","2000-01-03 00:00:00","2000-01-04 00:00:00","2000-01-05 00:00:00"]}}'::trajectory a
)
SELECT ST_Resample(a, '{"drop_point.distance_lesser":3}') from traj;
                                                                                                                                    st_resample                                                                                                                                     
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 {"trajectory":{"version":1,"type":"STPOINT","leafcount":4,"start_time":"2000-01-01 00:00:00","end_time":"2000-01-05 00:00:00","spatial":"LINESTRING(1 1,10 10,13 13,15 15)","timeline":["2000-01-01 00:00:00","2000-01-02 00:00:00","2000-01-04 00:00:00","2000-01-05 00:00:00"]}}
(1 row)