Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation
This project
Loading...
Sign in
谢明辉
/
VVAS-Match
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 960aa686
authored
Jun 14, 2022
by
李乾广
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
[chg]日志优化
1 parent
ec549f78
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
src/main/java/com/viontech/match/service/PersonService.java
src/main/java/com/viontech/match/service/PersonService.java
View file @
960aa68
...
...
@@ -110,11 +110,11 @@ public class PersonService {
List
<
BodyFeature
>
bodyFeatures
=
person
.
getBodyFeatures
();
Double
[]
feature
=
null
;
if
(
CollectionUtils
.
isEmpty
(
bodyFeatures
)
&&
null
==
person
.
getBodyMinScore
())
{
log
.
info
(
"
CountMatchPerson人体特征为空并且最小分数为空,直接查数量,PoolIds:[{}],count:{}"
,
poolIds
,
count
);
log
.
info
(
"
rid:{} CountMatchPerson人体特征为空并且最小分数为空,直接查数量,PoolIds:[{}],count:{}"
,
rid
,
poolIds
,
count
);
}
else
if
(
CollectionUtils
.
isNotEmpty
(
bodyFeatures
)){
feature
=
bodyFeatures
.
get
(
0
).
getFeature
();
if
(
feature
==
null
||
feature
.
length
<
Constant
.
BODY_FEATURE_DIMS_2048
)
{
log
.
info
(
"
人体特征维数小于2048,跳过比对"
);
log
.
info
(
"
rid:{} 人体特征维数小于2048,跳过比对"
,
rid
);
ResponseVo
error
=
ResponseVo
.
error
(
rid
,
"人体特征维数小于2048,跳过比对"
);
error
.
setCount
(
0
);
return
error
;
...
...
@@ -126,7 +126,7 @@ public class PersonService {
feature
=
Arrays
.
copyOfRange
(
feature
,
3
,
Constant
.
BODY_FEATURE_DIMS_2048
+
3
);
}
}
else
{
log
.
info
(
"
参数错误"
);
log
.
info
(
"
rid:{} 参数错误"
,
rid
);
ResponseVo
error
=
ResponseVo
.
error
(
rid
,
"参数错误"
);
error
.
setCount
(
0
);
return
error
;
...
...
@@ -136,7 +136,7 @@ public class PersonService {
ValueCountAggregationBuilder
countAggregationBuilder
=
AggregationBuilders
.
count
(
"countId"
).
field
(
"_id"
);
builder
.
aggregation
(
countAggregationBuilder
);
request
.
source
(
builder
);
log
.
debug
(
"
CountMatchPerson条件{}:{}"
,
indices
,
builder
.
toString
());
log
.
debug
(
"
rid:{} CountMatchPerson条件{}:{}"
,
rid
,
indices
,
builder
.
toString
());
SearchResponse
response
=
client
.
search
(
request
,
RequestOptions
.
DEFAULT
);
ParsedValueCount
countId
=
response
.
getAggregations
().
get
(
"countId"
);
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment