Commit Graph

486 Commits (d195c77ebc0d1c88ffe4d9b817c83713e6b6a8e5)

Author SHA1 Message Date
Alexander Belyaev d195c77ebc
Add a 2D landmark cost function. (#868)
[RFC=0011](https://github.com/googlecartographer/rfcs/blob/master/text/0011-landmarks.md)
2018-02-01 13:39:24 +01:00
Christoph Schütte 60e9fa59fe
Implement AddImuDataHandlerTest (#872)
This PR introduces first gRPC handler test that takes advantage of new RpcHandlerTestServer.
2018-02-01 13:05:08 +01:00
Alexander Belyaev e735203a05
Extend MapById::lower_bound() to support structs with 'time' field. (#871)
[RFC=0011](https://github.com/googlecartographer/rfcs/blob/master/text/0011-landmarks.md)
2018-02-01 11:58:13 +01:00
Alexander Belyaev ab890a8e15
Move 3D landmark cost function to mapping_3d/. (#870)
[RFC=0011](https://github.com/googlecartographer/rfcs/blob/master/text/0011-landmarks.md)
2018-01-31 18:40:10 +01:00
Alexander Belyaev 0440761474
Move slerp and scaling of error to 'cost_helpers'. (#864)
[RFC=0011](https://github.com/googlecartographer/rfcs/blob/master/text/0011-landmarks.md)
2018-01-31 17:06:49 +01:00
Rodrigo Queiro ad4dc3c4d3 Bazel: build with -Wno-sign-compare (#863)
This avoids warnings for code like:

```
  CHECK_EQ(local_to_cloud_trajectory_id_map_.count(local_trajectory_id), 0);
```
2018-01-31 15:19:36 +01:00
Alexander Belyaev 708e7fc57d
Add a 'cost_helpers' library. (#862)
* Add a 'cost_helpers' library.

* Change naming and add comments.
2018-01-30 22:12:25 +01:00
Alexander Belyaev 93568641f9
Implement LandmarkCostFunction 3D. (#860) 2018-01-30 15:18:13 +01:00
Alexander Belyaev 8316444319
Store landmark observations as LandmarkNodes in PoseGraph. (#850) 2018-01-29 10:17:05 +01:00
gaschler dab69e0ca0 Struct SensorId (#839)
* WIP, started unordered_set<SensorId>

* struct SensorId. Works for cartographer without grpc.

* correct test

* SensorId in cartographer_grpc/

* clean up

* try to fix for trusty

* SensorId::operator==

* Ran clang-format.
2018-01-26 15:07:49 +01:00
Christoph Schütte edb18231b6 Add ProtoStreamWriterInterface and implement forwarding writer. (#849) 2018-01-25 15:27:50 +01:00
Alexander Belyaev 894bad397d
Rename Landmark->LandmarkObservation. (#847) 2018-01-25 12:10:30 +01:00
Alexander Belyaev aee1bc46dc
Introduce InMemoryProtoStreamReader. (#844)
* Introduce InMemoryProtoStreamReader.

* Move inmemory*.* to in_memory*.*.
2018-01-24 13:58:15 +01:00
Alexander Belyaev 43008d391d
Introduce a ProtoStreamReaderInterface. (#837)
* Introduce a ProtoStreamReaderInterface.

* Remove the comments from interface def.
2018-01-23 09:09:37 +01:00
Alexander Belyaev 986ac28ff8
Rename 'tranform' to 'landmark_to_tracking_transform'. (#836) 2018-01-22 18:30:14 +01:00
Alexander Belyaev 6d4649857a
Move implementation of ReadProto/WriteProto to .cc (#835) 2018-01-22 17:53:31 +01:00
Rodrigo Queiro 0c227097e7 Add a Bazel build for cartographer (#834)
This does not include cartographer_grpc, nor any of the binaries
(*_main.cc). It has been tested with Bazel 0.9.0 on Ubuntu 14.04 with
the latest (at time of writing) dazel/dazel container, by running:

```
bazel build //...
bazel test //...
```

While this is a large CL, the files under third_party are not new - they have been through internal review, and this is their open-source release. The other files come to 212 lines of code.
2018-01-22 16:47:07 +01:00
Alexander Belyaev 67850d25a0 Replace templates in io/proto_stream.h with upcasting. (#833) 2018-01-22 14:12:14 +01:00
Alexander Belyaev 746c9c83c8
Propagate LandmarksData to the PoseGraph. (#830)
Propagate LandmarkData to the PoseGraph.
2018-01-19 09:41:24 +01:00
gaschler de5937856d Collate_by_trajectory option (#828)
Adds an option to create a MapBuilder using TrajectoryCollator
(instead of Collator).

[RFC=0008](https://github.com/googlecartographer/rfcs/blob/master/text/0008-collator-interface.md)
2018-01-17 21:15:15 +01:00
gaschler d92040d0e6 Test Collator for multiple trajectories (#829) 2018-01-17 20:43:20 +01:00
gaschler 70e378b7c5 TrajectoryCollator (#827)
Introduces TrajectorCollator, which collates sensor data ignoring
other trajectories.
Tests the same.

[RFC=0008](https://github.com/googlecartographer/rfcs/blob/master/text/0008-collator-interface.md)
2018-01-17 17:48:20 +01:00
Wolfgang Hess ffdbf1c161 Fix debug output for 3D loop closure error. (#826)
PAIR=spielawa
2018-01-17 13:09:48 +01:00
gaschler f64eef876a Optional GetBlockingTrajectoryId (#820)
[RFC=0008](https://github.com/googlecartographer/rfcs/blob/master/text/0008-collator-interface.md)
2018-01-16 16:21:22 +01:00
Alexander Belyaev 53c2a6b58f
Move 'finished' getter to the base class. (#803)
* Move 'finished' getter to the base class.

* Ran clang-format.

* Ran clang-format.
2018-01-16 14:20:33 +01:00
Christoph Schütte 31ec89614c Add parameter to Submap::ToProto() to determine whether to include loop (#821) 2018-01-16 11:23:29 +01:00
Christoph Schütte 3660408ae6 Forward declare unique_ptr<LocalSlamResultData> (#824) 2018-01-16 10:20:51 +01:00
gaschler 057bd8ce6a Public SpaCostFunction::Compute* (#814) 2018-01-12 21:46:47 +01:00
Wolfgang Hess 19ff047a79 Allow FixedRatioSampler to drop all data. (#817)
This is useful to disable loop closure by setting
constraint_builder.sampling_ratio = 0.
2018-01-12 18:54:41 +01:00
Christoph Schütte 1de696d45f Introduce PoseGraphInterface::ToProto() (#813) 2018-01-12 13:55:14 +01:00
Christoph Schütte fee77c8a99 Add LocalSlamResultData retrieval and submap management (#810)
[RFC=0002](https://github.com/googlecartographer/rfcs/blob/master/text/0002-cloud-based-mapping-1.md)
2018-01-12 13:00:25 +01:00
gaschler 51ccee3e74 CollatorInterface (#808)
[RFC=0008](https://github.com/googlecartographer/rfcs/blob/master/text/0008-collator-interface.md)
2018-01-11 16:02:03 +01:00
Christoph Schütte 8fc64fdbb5 Wrap HybridGrid in unique_ptr to make Submap updatable (#809) 2018-01-11 14:34:56 +01:00
Christoph Schütte e1a182d1fa Implement LocalSlamResult data adding to PoseGraph. (#804) 2018-01-11 10:19:37 +01:00
Christoph Schütte d313af8674
Add InsertionResult to LocalSlamResult. (#801) 2018-01-10 17:26:04 +01:00
Susanne Pielawa c7a8c5fda9 Keep fixed frame across optimizations. (#807)
PAIR=wohe
2018-01-10 16:01:27 +01:00
Susanne Pielawa 286d16238e In optimization_problem, use a map instead of vector for trajectory data. (#805)
PAIR=wohe
2018-01-10 14:30:51 +01:00
Susanne Pielawa 67d26747cc Implement assignment operator for common::optional. (#800)
Implement assignment operator for common::optional.
2018-01-09 17:54:53 +01:00
Christoph Schütte 8c7c4e3d2a Make LocalTrajectoryBuilder optional. (#799)
This is to prepare for the cloud-based mapping case where the robot is running cartographer in pure-localization mode and the cloud instance only solves the global problem. In that case a `LocalTrajectoryBuilder` need to be instantiated in for the cloud instance.
2018-01-09 16:54:30 +01:00
Christoph Schütte 8165da873f Add GetConstraints() to gRPC service. (#798) 2018-01-09 14:25:28 +01:00
Christoph Schütte 78d05bf745 Add GetTrajectoryNodePoses() to gRPC service (#796) 2018-01-08 14:19:39 +01:00
Christoph Schütte d57c2441b8 Implement gRPC submap query. (#794) 2018-01-08 13:52:14 +01:00
Susanne Pielawa 91034eaf58 Making pose in FixedFramePoseData optional. (#792)
This is for the case that the GPS signal is not available.
2018-01-08 11:37:07 +01:00
Christoph Schütte 196b4b891c Add PoseGraphInterface::GetTrajectoryNodePoses() (#795) 2018-01-08 09:13:51 +01:00
Christoph Schütte 1a837ef3ab Introduce PoseGraphInterface::GetAllSubmapPoses() (#790) 2018-01-05 14:19:08 +01:00
Susanne Pielawa 63a80c9340 Adding a minimal implementation of std::optional. (#783)
We're using C++11, which doesn't have std::optional. We need a few
features of std::optional for improved GPS support. These are
implemented here.
2018-01-05 11:27:21 +01:00
Juraj Oršulić 58d94aaa68 Refactor calling optimization into DispatchOptimization. (#729)
I noticed that @jihoonl opened the PR #726 which performs a similar thing. As discussed in googlecartographer/cartographer_ros#613 (@cschuet  has already taken a look), I pulled this out of #481 (a really old PR whose merging has been postponed), which is an example where re-running optimization is triggered from elsewhere as well (besides from `ComputeConstraintsForNode`). This refactoring makes libcartographer friendlier for use cases such as that one.

An important detail is that I have changed the condition in `WaitForAllComputations` to also check if the work queue is empty. If there are other things on the worker queue besides `ComputeConstraintsForNode`, currently we will wrongfully conclude that all computations are done. (This detail was merged in #754, so it's no longer in the diff of this PR).

Also missing is the same thing for 3D. I can add that when we settle on this.

Also, I suggest that `run_loop_closure` gets renamed to `run_optimization`.
2018-01-05 10:43:56 +01:00
Jihoon Lee 2ad83662f2 Migrate SubmapTexture and SubmapSlice logics from cartographer_ros (#782)
Towards [RFC06](https://github.com/googlecartographer/rfcs/blob/master/text/0006-serve-ros-map-from-pbstream.md).

Migrates
* `FillSubmapSlice` from `pbstream_to_rosmap_main.cc` 
* `SubmapTexture` logics from cartographer_ros
2018-01-04 10:52:05 +01:00
Juraj Oršulić 9ee65293d2 Pose graph: do not mark all submaps finished when finalizing a trajectory. (#784)
I think this was a mistake in #563 (@jihoonl). Not all submaps should be marked as finished, only those pertaining to the trajectory being finalized.
2018-01-04 10:11:28 +01:00
gaschler dbb3f7cde4 Test TrajectoryBuilderStub (#780) 2018-01-03 14:56:56 +01:00