【Big-Data】数据库基础知识
数据库基础
整体架构图
模块详情
Mysql: https://blog.csdn.net/ThinkWon/article/details/104778621
Redis: https://blog.csdn.net/ThinkWon/article/details/103522351
【Golang】Service mesh详解
Definition
Service Mesh是一个可配置的、低时延的架构层应用,主要应用在微服务框架中,用来处理内部微服务的海量数据通信的一种主要基于应用层API编写的框架。整体可以参考下图:
我们从用户发起请求到请求被返回的流程对service mesh负责的各个功能和模块进行拆解。
Container Orchestration Framework
这是一个系统引擎,当外部请求进入到系统内部时,首先访问到整个Framework,这个Framework能够对微服务框架的所有功能模块进行全局和局部的配置以及管理,并在这个基础上提供不同粒度的功能,例如维护服务发现表,进行内部网负载均衡等。
Load Balancing
当有大量流量进入到系统内部时,该功能模块从tr...
【Golang】Goroutine截获输出和错误
Goroutine获取输出
通过chan获取到输出。
参考这个程序代码:
https://github.com/Chengru-Song/algo_practice/blob/master/conc/conc.go
func ConcPattern() {
ch1 := make(chan int)
ch2 := make(chan int)
// var wg sync.WaitGroup
// wg.Add(1)
// wg.Wait()
go func(ch chan int) {
time.Sleep(time.Second * 1)
ch <- 1
}(ch1)
go func(ch chan int) {
// defer wg.D...
【Golang】Golang Map并发编程
Golang Map并发读写
直接并发读写
如果直接对map进行并发读写,那么会造成Panic或者error,如下所示:
package main
func main() {
m := make(map[int]int)
go func() {
for {
read := m[0] // sync read
}
}()
go func() {
for {
m[0] = 1 // sync write
}
}()
}
上面程序有问题
传统加锁读写
package main
func main() {
m := make(map[int]int)
mc := sync.Mutex
...
【AI】Item2Vec详解
item2vec
Usage: item2vec learns item similarity.
Motivation
Item2item relations are important because different than the traditional user2item relations, it shows a more explicit user intent of purchasing. Therefore it has a higher click-through rate.
Solution
Skip Gram
Skip-gram is used to predict context words given a target word.
For...
【AI】WMAPE详解
WMAPE
Advantage: The advantage of this metric over MAPE is that this overcomes the ‘infinite error’ issue.
Key word: Evaluation
Usage: A measure of prediction accuracy of a forecasting method.
WMAPE: weighted mean absolute percentage error’
A measure of prediction accuracy of a forecasting method.
\[\begin{equation}
WMAPE = \frac{\sum^n_{t=1...
【AI】LSTM+CNN详解
LSTM + CNN
Introduction
Solution
Why sigmoid?
Sigmoid function is 0 - 1 layout, it could be used to remember or forget something.
Why tanh
We want to avoid vanishing gradient problem. The second derivative of tanh is mo
【Golang】Golang语言基础(面经)
Basic Knowledge
声明
短变量声明只能在函数内部使用
package main
// myvar := 1 // false
var myvar = 1 // right
func main() {
}
不能使用nil初始化未指定类型的变量
var x = nil // false
var x interface{} = nil // right
_ = x
字符串没有nil
var x string
if x == nil { // err
}
if x == "" {
x = "default"
}
Slice & Array
首先Slice和Array是有区别的,Slice是指针,而Array已经预...
共计 142 篇文章,18 页。