mirror of
https://github.com/ceres-solver/ceres-solver.git
synced 2026-08-30 00:50:37 +08:00
Fix missing ddd Schur specialization generation code
Change-Id: Ic808565844b0564b5fa5f94cbda69e9a18ac49ee
This commit is contained in:
@@ -74,6 +74,8 @@ SPECIALIZATIONS = [(2, 2, 2),
|
||||
|
||||
import schur_eliminator_template
|
||||
import partitioned_matrix_view_template
|
||||
import os
|
||||
import glob
|
||||
|
||||
def SuffixForSize(size):
|
||||
if size == "Eigen::Dynamic":
|
||||
@@ -118,6 +120,16 @@ def Specialize(name, data):
|
||||
f.write(data["SPECIALIZATION_FILE"] %
|
||||
(row_block_size, e_block_size, f_block_size))
|
||||
|
||||
# Generate the _d_d_d specialization.
|
||||
output = SpecializationFilename("generated/" + name,
|
||||
"Eigen::Dynamic",
|
||||
"Eigen::Dynamic",
|
||||
"Eigen::Dynamic") + ".cc"
|
||||
with open(output, "w") as f:
|
||||
f.write(data["HEADER"])
|
||||
f.write(data["DYNAMIC_FILE"] %
|
||||
("Eigen::Dynamic", "Eigen::Dynamic", "Eigen::Dynamic"))
|
||||
|
||||
# Factory
|
||||
with open(name + ".cc", "w") as f:
|
||||
f.write(data["HEADER"])
|
||||
@@ -222,6 +234,9 @@ def GenerateQueryFile():
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
for f in glob.glob("generated/*"):
|
||||
os.remove(f)
|
||||
|
||||
Specialize("schur_eliminator",
|
||||
schur_eliminator_template.__dict__)
|
||||
Specialize("partitioned_matrix_view",
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Ceres Solver - A fast non-linear least squares minimizer
|
||||
// Copyright 2015 Google Inc. All rights reserved.
|
||||
// Copyright 2017 Google Inc. All rights reserved.
|
||||
// http://ceres-solver.org/
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Ceres Solver - A fast non-linear least squares minimizer
|
||||
// Copyright 2015 Google Inc. All rights reserved.
|
||||
// Copyright 2017 Google Inc. All rights reserved.
|
||||
// http://ceres-solver.org/
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without
|
||||
|
||||
Reference in New Issue
Block a user