首页
Python
Java
IOS
Andorid
NodeJS
JavaScript
HTML5
【
ranker_worker.go
】的更多相关文章
ranker_worker.go
package outputDocs, numDocs := engine.rankers[shard].Rank(request.docs, request.options, request.countDocsOnly) request.rankerReturnChannel <- rankerReturnRequest{docs: outputDocs, numDocs: numDocs} } } func (engine *Engine) ranke…
wukong引擎源码分析之索引——part 3 文档评分 无非就是将docid对应的fields信息存储起来,为搜索结果rank评分用
之前的文章分析过,接受索引请求处理的代码在segmenter_worker.go里: func (engine *Engine) segmenterWorker() { for { request := <-engine.segmenterChannel //关键 tokensMap := make(map[string][]int) numTokens := 0 if !engine.initOptions.NotUsingSegmenter && request.data.Con…