Skip to content

array<->eigen conversions + assignment to block expressions work with arrays/expressions with nonzero lobound/base #471

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 33 commits into from
Sep 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
84be590
TiledRange1: can construct using a range of tile hashmarks
evaleev Aug 31, 2024
cf0e0ea
<-> Eigen::{Vector,Matrix,Tensor} conversions can handle DistArrays w…
evaleev Aug 31, 2024
9129da9
[skip ci] typo
evaleev Sep 4, 2024
959adb1
remove duplicate vlock copy in concat
evaleev Sep 4, 2024
4ed437c
introduced tile_ranges_match_trange(DistArray) for validating tile ra…
evaleev Sep 4, 2024
7f687b3
SizeArray is a viewable range
evaleev Sep 4, 2024
65b8520
fixed assignment to block expression from an expression with nonzero …
evaleev Sep 4, 2024
d9eb677
[skip ci] to_container.hpp -> range/conversion.hpp
evaleev Sep 4, 2024
6e5df0f
device::Env::initialize: use correct page sizes for Umpire allocation…
evaleev Sep 4, 2024
bf89f59
[skip ci] svd dox fixup
evaleev Sep 4, 2024
e78e231
TiledRange1{int x} constructs an empty element range at [x,x)
evaleev Sep 8, 2024
8185cc5
make Range1 printable and shiftable
evaleev Sep 9, 2024
f10d61b
make TiledRange1 shiftable
evaleev Sep 8, 2024
ddce13e
TiledRange1 printer reimplemented in terms of Range1 printer
evaleev Sep 9, 2024
e005548
[skip ci] dox++
evaleev Sep 9, 2024
ffd8151
Range::shift is const
evaleev Sep 9, 2024
cb9f085
Range::shift is nodiscard
evaleev Sep 9, 2024
57907cc
TiledRange is shiftable
evaleev Sep 9, 2024
6e8624a
introduced BlkTsrExpr::{{set_,}trange_lobound,preserve_lobound}() tha…
evaleev Sep 11, 2024
5cc3ce3
dox fixup [skip ci]
evaleev Sep 13, 2024
2527e80
introduced TiledRange::is_congruent
evaleev Sep 13, 2024
1471c8b
like contraction, reduction expression and binary expression can igno…
evaleev Sep 13, 2024
d4142d7
introduced TiledRange1::{lo,up}bound which feel to have unambiguous m…
evaleev Sep 14, 2024
2f80dc0
more TsrExpr::block variants tagged by preserve_lobound_t
evaleev Sep 14, 2024
7820909
TA::expressions::preserve_lobound_t -> TA::preserve_lobound_t
evaleev Sep 15, 2024
4d4c06b
btas <-> ta tensor conversions work for non-0-lobound
evaleev Sep 15, 2024
057df5a
introduced member versions of TiledRange1::make_uniform
evaleev Sep 16, 2024
3409235
TiledRange1::make_uniform(rng) with empty range preserves its lobound
evaleev Sep 17, 2024
456b790
heig: work around the n=0 corner case
evaleev Sep 17, 2024
d622383
bump MAD tag to pull in https://github.com/m-a-d-n-e-s-s/madness/pull…
evaleev Sep 17, 2024
a0c0450
BinaryExpr: account for ignore_tile_position when checking preconditions
evaleev Sep 18, 2024
2ba8f8b
[python] simplify make_trange by using TiledRange1::make_uniform
evaleev Sep 18, 2024
ae1cf06
[ci] greatly reduce the gitlab matrix, replace rel/deb builds with re…
evaleev Sep 18, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,22 +57,22 @@ ubuntu:
metrics: build/metrics.txt
parallel:
matrix:
- IMAGE : [ "ubuntu:22.04", "ubuntu:20.04" ]
- IMAGE : [ "ubuntu:20.04" ]
CXX: [ g++ ]
BUILD_TYPE : [ "Release" ]
BUILD_TYPE : [ "RelWithDebInfo" ]
BLA_VENDOR : [ "BLAS_PREFERENCE_LIST=IntelMKL" ]
BLA_THREADS : [ "IntelMKL_THREAD_LAYER=tbb" ]
# ENABLE_SCALAPACK : [ "ENABLE_SCALAPACK=ON", "ENABLE_SCALAPACK=OFF" ]
TA_PYTHON : [ "TA_PYTHON=OFF" ] # needs to be fixed for MKL
RUNNER_TAGS: [ saas-linux-small-amd64 ]
- IMAGE : [ "ubuntu:22.04", "ubuntu:20.04" ]
- IMAGE : [ "ubuntu:22.04" ]
CXX: [ g++, clang++-13 ]
BUILD_TYPE : [ "Release", "Debug" ]
BUILD_TYPE : [ "RelWithDebInfo" ]
ENABLE_SCALAPACK : [ "ENABLE_SCALAPACK=ON", "ENABLE_SCALAPACK=OFF" ]
RUNNER_TAGS: [ saas-linux-small-amd64 ]
- IMAGE : [ "ubuntu:22.04", "ubuntu:20.04" ]
- IMAGE : [ "ubuntu:22.04" ]
CXX: [ g++ ]
BUILD_TYPE : [ "Release", "Debug" ]
BUILD_TYPE : [ "RelWithDebInfo" ]
ENABLE_CUDA : [ "ENABLE_CUDA=ON" ]
TA_TARGETS : [ "tiledarray examples-tiledarray check_serial-tiledarray" ]
RUNNER_TAGS: [ cuda ]
2 changes: 1 addition & 1 deletion INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ Both methods are supported. However, for most users we _strongly_ recommend to b
- [Range-V3](https://github.com/ericniebler/range-v3.git) -- a Ranges library that served as the basis for Ranges component of C++20 and later.
- [BTAS](http://github.com/ValeevGroup/BTAS), tag 4e8f5233aa7881dccdfcc37ce07128833926d3c2 . If usable BTAS installation is not found, TiledArray will download and compile
BTAS from source. *This is the recommended way to compile BTAS for all users*.
- [MADNESS](https://github.com/m-a-d-n-e-s-s/madness), tag 96ac90e8f193ccfaf16f346b4652927d2d362e75 .
- [MADNESS](https://github.com/m-a-d-n-e-s-s/madness), tag 95589b0d020a076f93d02eead6da654b23dd3d91 .
Only the MADworld runtime and BLAS/LAPACK C API component of MADNESS is used by TiledArray.
If usable MADNESS installation is not found, TiledArray will download and compile
MADNESS from source. *This is the recommended way to compile MADNESS for all users*.
Expand Down
4 changes: 2 additions & 2 deletions external/versions.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ set(TA_INSTALL_EIGEN_PREVIOUS_VERSION 3.3.7)
set(TA_INSTALL_EIGEN_URL_HASH SHA256=b4c198460eba6f28d34894e3a5710998818515104d6e74e5cc331ce31e46e626)
set(TA_INSTALL_EIGEN_PREVIOUS_URL_HASH MD5=b9e98a200d2455f06db9c661c5610496)

set(TA_TRACKED_MADNESS_TAG 96ac90e8f193ccfaf16f346b4652927d2d362e75)
set(TA_TRACKED_MADNESS_PREVIOUS_TAG 3d0ae2fad1b97e347ca6dd98b9f1b9e74e629f52)
set(TA_TRACKED_MADNESS_TAG 95589b0d020a076f93d02eead6da654b23dd3d91)
set(TA_TRACKED_MADNESS_PREVIOUS_TAG 96ac90e8f193ccfaf16f346b4652927d2d362e75)
set(TA_TRACKED_MADNESS_VERSION 0.10.1)
set(TA_TRACKED_MADNESS_PREVIOUS_VERSION 0.10.1)

Expand Down
7 changes: 1 addition & 6 deletions python/src/TiledArray/python/trange.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ auto list(const TiledRange &trange) {
return v;
}

// template<>
inline TiledRange make_trange(std::vector<std::vector<int64_t> > trange) {
std::vector<TiledRange1> trange1;
for (auto tr : trange) {
Expand All @@ -58,11 +57,7 @@ inline TiledRange make_trange(std::vector<std::vector<int64_t> > trange) {
inline TiledRange make_trange(std::vector<int64_t> shape, size_t block) {
std::vector<TiledRange1> trange1;
for (size_t i = 0; i < shape.size(); ++i) {
std::vector<int64_t> tr1;
for (size_t j = 0; j <= (shape[i] + block - 1); j += block) {
tr1.push_back(std::min<int64_t>(j, shape[i]));
}
trange1.push_back(TiledRange1(tr1.begin(), tr1.end()));
trange1.emplace_back(TiledRange1::make_uniform(shape[i], block));
}
return TiledRange(trange1.begin(), trange1.end());
}
Expand Down
248 changes: 200 additions & 48 deletions src/TiledArray/conversions/btas.h

Large diffs are not rendered by default.

5 changes: 1 addition & 4 deletions src/TiledArray/conversions/concat.h
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ DistArray<Tile, Policy> concat(
using std::begin;
using std::end;

index b(r), e(r); // updated for concatted modes only
index b(r), e(r); // updated for concatenated modes only
std::fill(begin(b), end(b), 0);
for (auto i = 0ul; i != arrays.size(); ++i) {
auto& tr = arrays[i].trange();
Expand Down Expand Up @@ -97,9 +97,6 @@ DistArray<Tile, Policy> concat(
result.make_tsrexpr(annot).block(tile_begin_end[i].first,
tile_begin_end[i].second) =
arrays[i].make_tsrexpr(annot);
result.make_tsrexpr(annot).block(tile_begin_end[i].first,
tile_begin_end[i].second) =
arrays[i].make_tsrexpr(annot);
}
}
result.world().gop.fence();
Expand Down
Loading
Loading