Out of Memory converting SVG

A forum dedicated to the Draft, Arch and BIM workbenches development.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
insp
Posts: 7
Joined: Sat Jan 23, 2021 2:11 pm

Out of Memory converting SVG

Post by insp »

Hello.
I have a problem converting SVG to Draft using "Convert bidirectionally between draft objects and Sketches".
Freecad eats up to 38G of memory and get killed by kernel
User avatar
PrzemoF
Veteran
Posts: 3520
Joined: Fri Jul 25, 2014 4:52 pm
Contact:

Re: Out of Memory converting SVG

Post by PrzemoF »

Welcome to the forum! Please provide info, as explained in the Help section of the forum.
insp
Posts: 7
Joined: Sat Jan 23, 2021 2:11 pm

Re: Out of Memory converting SVG

Post by insp »

file attached
flower.svg
(214.82 KiB) Downloaded 39 times
Steps to reproduce:
1. Load file as geometry
2. select Draft
3. Use "Convert bidirectional"
Freecad eats all available memory and gets killed.

Version information:
OS: Artix Linux (XFCE/Xfce Session)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.23578 (Git) AppImage
Build type: Release
Branch: master
Hash: 50c3cbf00579dc4941ca743c25720d016b0453ce
Python version: 3.8.6
Qt version: 5.12.5
Coin version: 4.0.0
OCC version: 7.4.0
Locale: English/United States (en_US)

Should I open a bug request?
Thank you for your help.
chrisb
Veteran
Posts: 54313
Joined: Tue Mar 17, 2015 9:14 am

Re: Out of Memory converting SVG

Post by chrisb »

There are several improvements concerning SVGs in 0.19.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
insp
Posts: 7
Joined: Sat Jan 23, 2021 2:11 pm

Re: Out of Memory converting SVG

Post by insp »

I am using Version: 0.19.23578 (Git) AppImage
chrisb
Veteran
Posts: 54313
Joined: Tue Mar 17, 2015 9:14 am

Re: Out of Memory converting SVG

Post by chrisb »

I think the flower is far too complex. You may tell us more about the big picture, what do you want to achieve in the end. You may get better help then.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
heda
Veteran
Posts: 1348
Joined: Sat Dec 12, 2015 5:49 pm

Re: Out of Memory converting SVG

Post by heda »

any particular reason why you "have" to use the sketcher?
the svg loads just fine and is responsive in draft, and with draft/part wb you can probably do what you are looking for - just a different way and workflow compared to using the sketcher (including using a set of lines to make solids).

with that said, you are probably going to get further if you only do path by path to sketcher,
just doing the outer path is completing in a second (on a old subpar laptop), and has close to 800 dofs - just imagine how many dofs in total it would be for for all 600+ paths if you do it in one go.
insp
Posts: 7
Joined: Sat Jan 23, 2021 2:11 pm

Re: Out of Memory converting SVG

Post by insp »

The reason I have to use sketcher is that I want to generate Gcode.
convert svg to sketch, then "Create job", then "Engraving operation"

Actually this flower doesn't seem to be very complex I am really surprised freecad can't handle it.
chrisb
Veteran
Posts: 54313
Joined: Tue Mar 17, 2015 9:14 am

Re: Out of Memory converting SVG

Post by chrisb »

insp wrote: Mon Jan 25, 2021 9:18 am Actually this flower doesn't seem to be very complex I am really surprised freecad can't handle it.
800 degrees of Freedom sounds rather complex. It may not have many lines, but each of them is a not at all trivial B-spline.

You don't have to convert these to sketches, you can engrave the paths directly. I would strongly recommend to use the symmetry of the flower together with the PathArray operation.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
insp
Posts: 7
Joined: Sat Jan 23, 2021 2:11 pm

Re: Out of Memory converting SVG

Post by insp »

Please, describe the workflow in a few words for engraving paths directly.
Post Reply