get invalid pointer or invalid free() error when copying adjacency_matrix to a vector
Maintainer thường phản hồi trong vòng 1 ngày
@jeremy-murphy đang làm issue này rồi.
Từ ngày 19/12/2022.
Đánh giá
Issue này chưa được đánh giá.
Mô tả
I have been trying to preload adjacency matrices with bundled properties to a std::vector of adjacency matrices in order to benchmark some uni project algorithm and not by chance measure the time to set up the graph.
In that instance i tried different approaches to copy a prototype g0:
- std::fill wouldn't work as AM is not a value type.
- boost::copy_graph() wouldn't work due to AM not being a list type
- using std::vector::emplace to construct the graph in place using a constructor declared in the documentation and the AM.hpp: one (of 2) with the edge iterators and num_nodes. * Luckily boost::edges(graph_t) provides such a thing. But it wouldn't work as the edge-iterator-pair provided does not include a .first member. There is one that needs an a property iterator ep_it. i haven't found any information on how do make one and if this is meant for bundled properties.
- using std::vector::push_back(g0) which works until the final "}" and then crashes when freeing or with a "munmap_chunk(): invalid pointer" error. g0 being a predefined graph i want to fill the vector with. It seems plausible as AM seems to be copy constructible. But apparently not entirely. Or maybe the property maps aren't.
However: after running through the algorithms there seems to be no change to g0. So it does not seem to be a "shallow copy" problem. Also valgrind does not report any memory leaks. But lots of errors.
This also happens when copy constructing only 2 graphs.
- on a sidenote: the documentation for iterator constructible suggests passing the number of edges too as it may speed up some processes. The AM does not seem to provide such a thing in the documentation in the section member functions (i.e. constructors).
- Ngôn ngữ chính
- C++
- Star
- 400
- Fork
- 249
- Merge trung bình
- 1 ngày 20 giờ
- Pull request đã merge (30 ngày)
- 48
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của boostorg/graph
-
Good first issues: start contributing to Boost.Graph hereCó thể làm lại được @andreacassioli đã nhận 13 ngày trước và không có pull request nào đang mở. Đang mởbeginner friendly
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
boostorg/graph#593 · 55 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
algorithm beginner friendly priority: high
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
boostorg/graph#231 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
boykov_kolmogorov_max_flow: color map is not a minimum cut when a vertex has two edges to the sinkCó thể đã có người làm @BayKeremm đã nhận 2 ngày trước. Đang mởalgorithm
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 35/100
boostorg/graph#655 · 5 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Trivial Minimum Cycle Ratio FailingCó thể đã có người làm @Becheler đã nhận 16 ngày trước. Đang mởalgorithm
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 68/100
boostorg/graph#599 · 3 bình luận · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 30/100
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của boostorg/graph
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
bulletphysics/bullet3#4819 ·
-
[YSQL] Local-node initdb reads postgres.bki, but YB clusters bootstrap only from yb_postgres.bkiĐang mởarea/ysql kind/enhancement priority/low status/awaiting-triage
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
yugabyte/yugabyte-db#35763 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
[mimalloc] update to 3.6.0Đang mởcategory:port-update
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 66/100
Maintainer thường phản hồi trong vòng 2 ngày
-
MinGW build faillureĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 67/100
facebookresearch/faiss#5775 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 2 ngày
-
Eval bug: minimax-m3: build_moe_ffn() drops the per-expert NVFP4 scale → garbled output (M3.1 Flash)Đang mởbug-unconfirmed
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
Maintainer thường phản hồi trong vòng 1 ngày