question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Segmentation Fault when attempting `get_buildings` and `get_network`

See original GitHub issue

Hello! Thanks for making this library. I am really liking using it so far.

I am having an issue with seg faults which I wanted to ask about solving. My computer has higher specs than the benchmark computer, including more ram. So I am unsure why it’s not even running.

In order to make a test case for it I picked a very small area, and ran the following on my computer with 32 gb ram.

from pyrosm import OSM, get_data

# Get map data
map_data = get_data('london')

osm = OSM(map_data, bounding_box=[-0.071654, 51.501862, -0.048006, 51.511343])

osm.get_network()

This gives a seg fault after about 5 seconds, the RAM use goes up to 9 GB. Of course I ran it without the bounding box. It also seg faults but goes up to 19 GB RAM use and takes about 10 seconds to fail.

Do you have any idea what could be wrong?

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:11 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
pyrosnowman24commented, Mar 9, 2022

I was able to get it working in Conda with: python==3.8.12 pyrosm==0.6.1 cython==0.29.28 cykhash==1.0.2 pygeos==0.10

It seems that pygeos 0.11 and newer cause the segmentation fault.

0reactions
janrucommented, May 18, 2022

I can confirm that the pygeos>0.10 seems to cause the issue with get_buildings(). pygeos v 0.12.0 -> segfault pygeos v 0.10 -> no segfault

Read more comments on GitHub >

github_iconTop Results From Across the Web

c++ - What is a segmentation fault? - Stack Overflow
Segmentation fault is a specific kind of error caused by accessing memory that “does not belong to you.” It's a helper mechanism that...
Read more >
Identify what's causing segmentation faults (segfaults)
A segmentation fault (aka segfault) is a common condition that causes programs to crash; they are often associated with a file named core...
Read more >
Segmentation fault - Wikipedia
In computing, a segmentation fault (often shortened to segfault) or access violation is a fault, or failure condition, raised by hardware with memory...
Read more >
How to Debug Node.js Segmentation Faults | HTTP Toolkit
A segmentation fault occurs when a program attempts to access a memory location that it is not allowed to access, or attempts to...
Read more >
NetworkManager - segfault - Unix & Linux Stack Exchange
A segmentation fault is typically due to a programming error or at least a special case that was not considered appropriately by the ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found