Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
L
localize_for_ppk
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wangdawei
localize_for_ppk
Commits
ce866287
Commit
ce866287
authored
May 23, 2023
by
wangdawei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test
parent
86d301a6
Pipeline
#1542
failed with stages
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
7 deletions
+11
-7
adjust_ppk.cpp
libs/locate_system/adjust_ppk_by_locate/adjust_ppk.cpp
+3
-2
convert.cc
libs/locate_system/adjust_ppk_by_locate/convert.cc
+8
-5
No files found.
libs/locate_system/adjust_ppk_by_locate/adjust_ppk.cpp
View file @
ce866287
...
@@ -16,9 +16,9 @@ AdjustPPK::AdjustPPK(const string &ieBaseDir, const string &mapDir)
...
@@ -16,9 +16,9 @@ AdjustPPK::AdjustPPK(const string &ieBaseDir, const string &mapDir)
LoadMapInfo
();
LoadMapInfo
();
CalLocalPose
();
CalLocalPose
();
CalPPKPeriod
();
CalPPKPeriod
();
std
::
ofstream
ofs
(
ieBaseDir_
+
"
/CloudPredictPose.txt"
,
ios
::
out
);
std
::
ofstream
ofs
(
"/home/juefx/wangdawei
/CloudPredictPose.txt"
,
ios
::
out
);
ofs
.
close
();
ofs
.
close
();
ofs
.
open
(
ieBaseDir_
+
"
/LocalPPK.txt"
,
ios
::
out
);
ofs
.
open
(
"/home/juefx/wangdawei
/LocalPPK.txt"
,
ios
::
out
);
ofs
.
close
();
ofs
.
close
();
Matrix4d
m
;
Matrix4d
m
;
/////////////// cpt ///////////////
/////////////// cpt ///////////////
...
@@ -35,6 +35,7 @@ AdjustPPK::AdjustPPK(const string &ieBaseDir, const string &mapDir)
...
@@ -35,6 +35,7 @@ AdjustPPK::AdjustPPK(const string &ieBaseDir, const string &mapDir)
void
AdjustPPK
::
ConfigConvert
(
const
string
&
firetimeFile
,
const
string
&
correctionFile
)
void
AdjustPPK
::
ConfigConvert
(
const
string
&
firetimeFile
,
const
string
&
correctionFile
)
{
{
convert_
.
reset
(
new
pandar_pointcloud
::
Convert
(
firetimeFile
,
correctionFile
));
convert_
.
reset
(
new
pandar_pointcloud
::
Convert
(
firetimeFile
,
correctionFile
));
LOG
(
INFO
)
<<
"ConfigConvert done"
;
}
}
void
AdjustPPK
::
ReadBag
(
const
string
&
bagPath
)
void
AdjustPPK
::
ReadBag
(
const
string
&
bagPath
)
...
...
libs/locate_system/adjust_ppk_by_locate/convert.cc
View file @
ce866287
...
@@ -200,8 +200,6 @@ Convert::Convert(const std::string &firetimeFile, const std::string &correctionF
...
@@ -200,8 +200,6 @@ Convert::Convert(const std::string &firetimeFile, const std::string &correctionF
// boost::thread publishPointsThr(
// boost::thread publishPointsThr(
// boost::bind(&Convert::publishPointsThread, this));
// boost::bind(&Convert::publishPointsThread, this));
init
();
}
}
bool
Convert
::
processScan
(
bool
Convert
::
processScan
(
...
@@ -592,6 +590,10 @@ void Convert::moveTaskEndToStartAngle() {
...
@@ -592,6 +590,10 @@ void Convert::moveTaskEndToStartAngle() {
}
}
void
Convert
::
init
()
{
void
Convert
::
init
()
{
static
bool
inited
=
false
;
if
(
inited
){
return
;
}
while
(
1
)
{
while
(
1
)
{
if
(
!
m_PacketsBuffer
.
hasEnoughPackets
())
{
if
(
!
m_PacketsBuffer
.
hasEnoughPackets
())
{
usleep
(
1000
);
usleep
(
1000
);
...
@@ -690,6 +692,7 @@ void Convert::init() {
...
@@ -690,6 +692,7 @@ void Convert::init() {
m_OutMsgArray
[
1
]
=
outMag1
;
m_OutMsgArray
[
1
]
=
outMag1
;
break
;
break
;
}
}
inited
=
true
;
}
}
void
Convert
::
publishPoints
()
{
void
Convert
::
publishPoints
()
{
...
@@ -1422,10 +1425,10 @@ bool Convert::processPacket(PPointCloud& pc)
...
@@ -1422,10 +1425,10 @@ bool Convert::processPacket(PPointCloud& pc)
static
int
pktCount
=
0
;
static
int
pktCount
=
0
;
static
int
cursor
=
0
;
static
int
cursor
=
0
;
if
(
!
m_PacketsBuffer
.
hasEnoughPackets
())
{
if
(
!
m_PacketsBuffer
.
hasEnoughPackets
())
{
usleep
(
1000
);
//
usleep(1000);
return
false
;
return
false
;
}
}
init
();
if
(
0
==
checkLiadaMode
())
{
if
(
0
==
checkLiadaMode
())
{
// ROS_WARN("checkLiadaMode now!!");
// ROS_WARN("checkLiadaMode now!!");
m_OutMsgArray
[
cursor
]
->
clear
();
m_OutMsgArray
[
cursor
]
->
clear
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment