上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 31 下一页
摘要: 出错伪代码如下: //出错的点在这里 import java.util.Date ... val t_rdd = t_frame.rdd.map(row => { val photo_url = row.getAs[String]("photo_url") val longitude = row.g 阅读全文
posted @ 2022-09-06 20:21 明月照江江 阅读(297) 评论(0) 推荐(0) 编辑
摘要: 项目需求需要空间计算能力,开始选型Sedona(GeoSpark)来完成, 需求需要每一条数据在满足某条件的情况下,去查找某张表进行空间匹配,找到离这个点(point)最近的一条道路(lineString) 第一个方案: 使用sedona来使用临近道路的判断 由于sedona本质还是使用spark的 阅读全文
posted @ 2022-09-06 20:10 明月照江江 阅读(673) 评论(0) 推荐(1) 编辑
摘要: 项目中用到的模块 API # 模块: import pandas as pd import numpy as np from scipy.optimize import curve_fit numpy np.array 创建ndarray np.polyfit 根据传入的x数组和y数组,及阶数,拟合 阅读全文
posted @ 2022-08-26 16:17 明月照江江 阅读(23) 评论(0) 推荐(0) 编辑
摘要: 计算2个几何相交结果时候,报错了: val geometry = polygon.intersection(lineString) 日志如下 org.locationtech.jts.geom.TopologyException: found non-noded intersection betwe 阅读全文
posted @ 2022-08-26 16:02 明月照江江 阅读(500) 评论(0) 推荐(0) 编辑
摘要: 滑动窗口技术是Sentinel比较关键的核心技术,主要用于数据统计 通过分析StatisticSlot来慢慢引出这个概念 @Override public void entry(Context context, ResourceWrapper resourceWrapper, DefaultNode 阅读全文
posted @ 2022-08-14 16:31 明月照江江 阅读(138) 评论(0) 推荐(0) 编辑
摘要: 直接从Sentinel 源码demo ExceptionRatioCircuitBreakerDemo看起 直接看他的main函数 public static void main(String[] args) throws Exception { initDegradeRule(); ...... 阅读全文
posted @ 2022-08-14 14:32 明月照江江 阅读(172) 评论(0) 推荐(0) 编辑
摘要: 1. git clone senetinel 源码到本地,切换到release1.8分支 2. 找到FlowQpsDemo.java, 根据sentinel自带的案例来学习sentinel的原理 3. 先看main方法 public static void main(String[] args) t 阅读全文
posted @ 2022-08-14 10:59 明月照江江 阅读(531) 评论(0) 推荐(0) 编辑
摘要: 使用Netflix的包 curator-recipes pom文件引入相关依赖 <dependency> <groupId>org.apache.zookeeper</groupId> <artifactId>zookeeper</artifactId> <version>3.6.3</versio 阅读全文
posted @ 2022-08-09 15:48 明月照江江 阅读(52) 评论(0) 推荐(0) 编辑
摘要: date-gen.py import datetime def date_generate(start_date, end_date): print(f'Hi, {start_date}, {end_date}') start_dt = datetime.datetime.strptime(star 阅读全文
posted @ 2022-07-08 10:13 明月照江江 阅读(466) 评论(0) 推荐(0) 编辑
摘要: spark-shell On Yarn spark-shell \ --master yarn-client \ --executor-memory 1G \ --num-executors 10 spark-sql On Yarn spark-sql \ --master yarn \ --exe 阅读全文
posted @ 2022-04-22 17:35 明月照江江 阅读(417) 评论(0) 推荐(0) 编辑
上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 31 下一页