From 1d896121e5a86a82594bee3460984d82cafe48c2 Mon Sep 17 00:00:00 2001 From: Rohit Goswami Date: Mon, 4 Aug 2025 20:23:55 +0200 Subject: [PATCH 1/2] MAINT: Switch to OpenBLAS for lapack by default --- make.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/make.in b/make.in index cbb9a62f..4cb3eb06 100644 --- a/make.in +++ b/make.in @@ -9,7 +9,7 @@ MAKEDEPEND=g++ -M $(CXXFLAGS) # Lapack includes and linking ILAPACK= -LLAPACK=-llapack +LLAPACK=-lopenblas TBSRC=../libs/ LDFLAGS=-L$(TBSRC) -ltoolbox $(LLAPACK) From ae46f30cda37fe5694bef95378990260c268de25 Mon Sep 17 00:00:00 2001 From: Rohit Goswami Date: Mon, 4 Aug 2025 20:25:08 +0200 Subject: [PATCH 2/2] MAINT: Add and use an explicit valarray ostream op --- libs/tbdefs.hpp | 14 ++++++++++++++ tools/dimproj.cpp | 8 ++++++-- tools/dimred.cpp | 16 +++++++++++----- 3 files changed, 31 insertions(+), 7 deletions(-) diff --git a/libs/tbdefs.hpp b/libs/tbdefs.hpp index 233c3104..5524195c 100644 --- a/libs/tbdefs.hpp +++ b/libs/tbdefs.hpp @@ -21,6 +21,20 @@ #include #include +template +std::ostream& operator<<(std::ostream& os, const std::valarray& v) +{ + os << "["; + if (v.size() > 0) { + os << v[0]; + for (size_t i = 1; i < v.size(); ++i) { + os << ", " << v[i]; + } + } + os << "]"; + return os; +} + /************************************** * MACROS & DEFINES * **************************************/ diff --git a/tools/dimproj.cpp b/tools/dimproj.cpp index bdef5421..cdba4460 100644 --- a/tools/dimproj.cpp +++ b/tools/dimproj.cpp @@ -124,7 +124,9 @@ int main(int argc, char**argv) else { csv2floats(fdhd,tfpars); fhdpars=tfpars; - std::cerr<<"high-dim pars"< sat(0.0,2); csv2floats(tempopts,sat); - std::cerr<<" simulated annealing ops: "<