Skip to content
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

[v630][RF] Backports of RooFit PRs to v6-30-00-patches: Part 8 #14252

Merged

Conversation

gartrog and others added 2 commits December 16, 2023 13:29
Fixes a small bug in calculation of product of diagonal terms in LU
matrix decompositions.

A unit test to cover the former bug is also implemented.
Instead of hard-coding 'lib' as the path to which minuit2 is installed
as a standalone library, use the user configurable CMAKE_INSTALL_LIBDIR.
As a particularly common example, this allows a user to specify the
library installation path to '${_prefix}/lib64' on 64-bit machines from
the cmake command line.
@phsft-bot
Copy link
Collaborator

Starting build on ROOT-performance-centos8-multicore/soversion, ROOT-ubuntu2204/nortcxxmod, ROOT-ubuntu2004/python3, mac12arm/cxx20, windows10/default
How to customize builds

Copy link

github-actions bot commented Dec 16, 2023

Test Results

         9 files           9 suites   1d 13h 0m 10s ⏱️
  2 481 tests   2 480 ✔️ 0 💤 1
21 361 runs  21 360 ✔️ 0 💤 1

For more details on these failures, see this check.

Results for commit bae08e7.

♻️ This comment has been updated with latest results.

cburgard and others added 2 commits December 16, 2023 19:12
In the current implementation, shapesys with no valid data (all
constraints constant) are written out in an invalid way, making it
impossible for the reader to then instantiate the correct number of
parameters. This PR fixes this by forcing the write-out of data with
all-zeros for such invalid shapesys. Alternatively, one could imagine
dropping these shapesys completely, but that's maybe something of a
policy decision that I don't want to make in a bugfix patch :)
Fixing a crash in HistoToWorkspaceFactoryFast.cxx where a parameter
that was globally set to be constant was not found a given region,
but the code was still accessing the parameter even when it was nullptr.
Now the parameter is set to constant only when found in a given region.
Also demoting the error to warning as this does not always indicate a
wrong setup.
@phsft-bot
Copy link
Collaborator

Starting build on ROOT-performance-centos8-multicore/soversion, ROOT-ubuntu2204/nortcxxmod, ROOT-ubuntu2004/python3, mac12arm/cxx20, windows10/default
How to customize builds

@ferdymercury
Copy link
Collaborator

ferdymercury commented Dec 18, 2023

Not sure if you want to catch in one of your PR also some stuff from the milestones: https://github.com/root-project/root/milestones/
Especially the VDT fix by dpiparo seems essential.

@phsft-bot
Copy link
Collaborator

Starting build on ROOT-performance-centos8-multicore/soversion, ROOT-ubuntu2204/nortcxxmod, ROOT-ubuntu2004/python3, mac12arm/cxx20, windows10/default
How to customize builds

guitargeek and others added 5 commits December 19, 2023 15:40
At some point in `RooGenProdProj::createIntegral()`, an intermediate
integral object that should only live during the scope of the function
is accidentally put in the `saveSet` output parameter. This needs to be
fixed.

Thanks to the following forum post for noticing this:
https://root-forum.cern.ch/t/error-inputarguments-rooargset-error-argument-with-name-is-already-in-this-set-in-roomcstudy/57571
When compiling with gcc 13.2, there is a new warning in TMVA that is
fixed by this commit:

```c++
In static member function ‘static constexpr _Up* std::__copy_move<_IsMove, true, std::random_access_iterator_tag>::__copy_m(_Tp*, _Tp*, _Up*) [with _Tp = long unsigned int; _Up = long unsigned int; bool _IsMove = true]’,
    inlined from ‘constexpr _OI std::__copy_move_a2(_II, _II, _OI) [with bool _IsMove = true; _II = long unsigned int*; _OI = long unsigned int*]’ at /usr/include/c++/13.2.1/bits/stl_algobase.h:506:30,
    inlined from ‘constexpr _OI std::__copy_move_a1(_II, _II, _OI) [with bool _IsMove = true; _II = long unsigned int*; _OI = long unsigned int*]’ at /usr/include/c++/13.2.1/bits/stl_algobase.h:533:42,
    inlined from ‘constexpr _OI std::__copy_move_a(_II, _II, _OI) [with bool _IsMove = true; _II = long unsigned int*; _OI = long unsigned int*]’ at /usr/include/c++/13.2.1/bits/stl_algobase.h:540:31,
    inlined from ‘constexpr _OI std::copy(_II, _II, _OI) [with _II = move_iterator<long unsigned int*>; _OI = long unsigned int*]’ at /usr/include/c++/13.2.1/bits/stl_algobase.h:633:7,
    inlined from ‘static _ForwardIterator std::__uninitialized_copy<true>::__uninit_copy(_InputIterator, _InputIterator, _ForwardIterator) [with _InputIterator = std::move_iterator<long unsigned int*>; _ForwardIterator = long unsigned int*]’ at /usr/include/c++/13.2.1/bits/stl_uninitialized.h:147:27,
    inlined from ‘_ForwardIterator std::uninitialized_copy(_InputIterator, _InputIterator, _ForwardIterator) [with _InputIterator = move_iterator<long unsigned int*>; _ForwardIterator = long unsigned int*]’ at /usr/include/c++/13.2.1/bits/stl_uninitialized.h:185:15,
    inlined from ‘constexpr _ForwardIterator std::__uninitialized_copy_a(_InputIterator, _InputIterator, _ForwardIterator, allocator<_Tp>&) [with _InputIterator = move_iterator<long unsigned int*>; _ForwardIterator = long unsigned int*; _Tp = long unsigned int]’ at /usr/include/c++/13.2.1/bits/stl_uninitialized.h:373:37,
    inlined from ‘constexpr _ForwardIterator std::__uninitialized_move_if_noexcept_a(_InputIterator, _InputIterator, _ForwardIterator, _Allocator&) [with _InputIterator = long unsigned int*; _ForwardIterator = long unsigned int*; _Allocator = allocator<long unsigned int>]’ at /usr/include/c++/13.2.1/bits/stl_uninitialized.h:399:2,
    inlined from ‘constexpr void std::vector<_Tp, _Alloc>::_M_range_insert(iterator, _ForwardIterator, _ForwardIterator, std::forward_iterator_tag) [with _ForwardIterator = const long unsigned int*; _Tp = long unsigned int; _Alloc = std::allocator<long unsigned int>]’ at /usr/include/c++/13.2.1/bits/vector.tcc:819:9,
    inlined from ‘constexpr std::vector<_Tp, _Alloc>::iterator std::vector<_Tp, _Alloc>::insert(const_iterator, std::initializer_list<_Tp>) [with _Tp = long unsigned int; _Alloc = std::allocator<long unsigned int>]’ at /usr/include/c++/13.2.1/bits/stl_vector.h:1411:17,
    inlined from ‘void TMVA::MethodDL::ParseInputLayout()’ at /home/rembserj/spaces/master/root/src/root/tmva/tmva/src/MethodDL.cxx:470:24:
/usr/include/c++/13.2.1/bits/stl_algobase.h:437:30: error: ‘void* __builtin_memmove(void*, const void*, long unsigned int)’ forming offset 32 is out of the bounds [0, 32] [-Werror=array-bounds=]
  437 |             __builtin_memmove(__result, __first, sizeof(_Tp) * _Num);
      |
```

The fix suggested in this commit is to directly assign from a full
initializer list, which is also more readable in the code.
In the RooFit `json_interface`, the calls to the actual JSON library are
abstracted away, such that the libraries like `nlohmann_json` are not
included in the headers.

Therefore, `nlohmann_json` is a private dependency of the RooFit JSON
interface, not a public one.
Using `nlohmann_json` as a public dependency of ROOT can result in
different troubles, like root-project#14188. That's why it's better to avoid this
dependency if we can, also to minimize the dependency of RooFit on the
interface level.

In the case of RooFit, the only reason for this dependency was the
`HeatmapAnalyzer::getMetadata()` function. However, it just returned a
json with a vector of string lables. We can also return a
`std::vector<std::string>` here.

I already talked with @Zeff020 about this change, and he is completely
fine with it. The class was also only used by the RooFit Multiprocess
developers so far, so changing the interface is fine.

With this interface change, only some refactoring was necessary to avoid
including `nlohmann_json` in the RooFit headers.

This commit is similar to 9d7aa4a.
@phsft-bot
Copy link
Collaborator

Starting build on ROOT-performance-centos8-multicore/soversion, ROOT-ubuntu2204/nortcxxmod, ROOT-ubuntu2004/python3, mac12arm/cxx20, windows10/default
How to customize builds

@guitargeek
Copy link
Contributor Author

guitargeek commented Dec 19, 2023

Not sure if you want to catch in one of your PR also some stuff from the milestones: https://github.com/root-project/root/milestones/ Especially the VDT fix by dpiparo seems essential.

Looks like these already got backported now.

I just backport my own commits in these PRs, plus some others if I'm aware of them. But in the end, it's our shared responsibility to make sure that these backports are all landing 🙂

@guitargeek guitargeek merged commit 793371f into root-project:v6-30-00-patches Dec 19, 2023
9 of 14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants