Civil engineering feature implementation (Transportation Engineering)

Have some feature requests, feedback, cool stuff to share, or want to know where FreeCAD is going? This is the place.
Forum rules
Be nice to others! Read the FreeCAD code of conduct!
User avatar
Joel_graff
Veteran
Posts: 1949
Joined: Fri Apr 28, 2017 4:23 pm
Contact:

Re: Civil engineering feature implementation (Transportation Engineering)

Post by Joel_graff »

That is pretty neat!

It looks like a spline-based implementation, which is generally useless for traditional transportation engineering design. Microelly and I spent several weeks trying to figure out how to design a spline that reduced to simple curves. I'm sure it's a solvable problem, but not within easy reach at this point.
FreeCAD Trails workbench for transportation engineering: https://www.github.com/joelgraff/freecad.trails

pivy_trackers 2D coin3D library: https://www.github.com/joelgraff/pivy_trackers
User avatar
Joel_graff
Veteran
Posts: 1949
Joined: Fri Apr 28, 2017 4:23 pm
Contact:

Re: Civil engineering feature implementation (Transportation Engineering)

Post by Joel_graff »

HakanSeven12 wrote: Fri Feb 12, 2021 7:04 am

Code: Select all

09:56:55  Traceback (most recent call last):
  File "C:\Users\hakan.seven\AppData\Roaming\FreeCAD\Mod\freecad.trails\freecad\trails\design\alignment\horizontal_alignment.py", line 546, in onChanged
    stations = self.get_stations(vobj.Object)
  File "C:\Users\hakan.seven\AppData\Roaming\FreeCAD\Mod\freecad.trails\freecad\trails\design\alignment\horizontal_alignment.py", line 601, in get_stations
    tuple_coord, tuple_vec = obj.Proxy.model.get_orthogonal( sta, "Left")
  File "C:\Users\hakan.seven\AppData\Roaming\FreeCAD\Mod\freecad.trails\freecad\trails\design\alignment\alignment_model.py", line 690, in get_orthogonal
    return _fn[curve.get('Type')].get_ortho_vector(
  File "C:\Users\hakan.seven\AppData\Roaming\FreeCAD\Mod\freecad.trails\freecad\trails\design\geometry\arc.py", line 812, in get_ortho_vector
    delta = distance / radius
<class 'ZeroDivisionError'>: float division by zero
Some of the alignments dont throw any error but labels looks not aligned.
Can you take a look again? I've imported the alignment, turned on labels, saved it, reloaded it, and it looks ok. The only issue is, if the alignment is saved with the labels turned on, it still reloads with the labels turned off.

I'm not convinced it's ok - I suspect there's something that's not being reloaded properly, but I can't consistently demonstrate a bug to squash.

Anyway, sorry it's taken me so incredibly long to work this out. Work has been getting busy these last few months.
FreeCAD Trails workbench for transportation engineering: https://www.github.com/joelgraff/freecad.trails

pivy_trackers 2D coin3D library: https://www.github.com/joelgraff/pivy_trackers
User avatar
HakanSeven12
Veteran
Posts: 1481
Joined: Wed Feb 06, 2019 10:30 pm

Re: Civil engineering feature implementation (Transportation Engineering)

Post by HakanSeven12 »

I dont think that a good idea to save and restore model from xml file. So I think my model keeper property working well. Because your solution couse permission errors. But we can use your exporter to export xml files to use with other softwares.
User avatar
Joel_graff
Veteran
Posts: 1949
Joined: Fri Apr 28, 2017 4:23 pm
Contact:

Re: Civil engineering feature implementation (Transportation Engineering)

Post by Joel_graff »

HakanSeven12 wrote: Fri May 07, 2021 6:46 am I dont think that a good idea to save and restore model from xml file. So I think my model keeper property working well. Because your solution couse permission errors. But we can use your exporter to export xml files to use with other softwares.
That's fine. I was just trying to follow up on this bug - it looks like it's working fine, now?
FreeCAD Trails workbench for transportation engineering: https://www.github.com/joelgraff/freecad.trails

pivy_trackers 2D coin3D library: https://www.github.com/joelgraff/pivy_trackers
User avatar
HakanSeven12
Veteran
Posts: 1481
Joined: Wed Feb 06, 2019 10:30 pm

Re: Civil engineering feature implementation (Transportation Engineering)

Post by HakanSeven12 »

I dont know. I didnt test it and I wont until next monday.
User avatar
HakanSeven12
Veteran
Posts: 1481
Joined: Wed Feb 06, 2019 10:30 pm

Re: Civil engineering feature implementation (Transportation Engineering)

Post by HakanSeven12 »

It works. The shape of alignments looks normal and create guidelines normally but throw this error. Also its complately not working for d1 kolu.

Code: Select all

11:16:32  unable to locate station  0.0 on curve  None
11:16:32  Traceback (most recent call last):
  File "C:\Users\hakan.seven\AppData\Roaming\FreeCAD\Mod\freecad.trails\freecad\trails\geomatics\guideline\guidelines.py", line 103, in execute
    obj.Shape = self.get_lines(base, alignment, offsets, stations)
  File "C:\Users\hakan.seven\AppData\Roaming\FreeCAD\Mod\freecad.trails\freecad\trails\geomatics\guideline\gl_func.py", line 78, in get_lines
    tuple_coord, tuple_vec = alignment.Proxy.model.get_orthogonal( sta, "Left")
<class 'TypeError'>: cannot unpack non-iterable NoneType object
jman
Posts: 4
Joined: Tue May 04, 2021 7:49 pm

Re: Civil engineering feature implementation (Transportation Engineering)

Post by jman »

Hi All,

If this is the wrong place to post this sort of question, just let me know and I can remove/post elsewhere.

I am trying to install Trails to be able to import some pretty high-res lidar data. However despite extracting trails and the privy_trackers (and the python support scripts) from github, the Trails module still doesn't seem to want to run, and I get the message below in the report:

Code: Select all

20:32:16  non-default argument follows default argument (gl_cluster.py, line 34)
20:32:16  Traceback (most recent call last):
  File "C:\Users\<username>\AppData\Roaming\FreeCAD\Mod\trails\freecad\trails\init_gui.py", line 247, in Initialize
    from .geomatics.section import CreateGuideLines
  File "C:\Program Files\FreeCAD 0.19\bin\Lib\site-packages\shiboken2\files.dir\shibokensupport\__feature__.py", line 142, in _import
    return original_import(name, *args, **kwargs)
  File "C:\Users\<username>\AppData\Roaming\FreeCAD\Mod\trails\freecad\trails\geomatics\section\__init__.py", line 1, in <module>
    from . import CreateGuideLines
  File "C:\Program Files\FreeCAD 0.19\bin\Lib\site-packages\shiboken2\files.dir\shibokensupport\__feature__.py", line 142, in _import
    return original_import(name, *args, **kwargs)
  File "C:\Users\<username>\AppData\Roaming\FreeCAD\Mod\trails\freecad\trails\geomatics\section\CreateGuideLines.py", line 28, in <module>
    from . import gl_clusters, gl_cluster
  File "C:\Program Files\FreeCAD 0.19\bin\Lib\site-packages\shiboken2\files.dir\shibokensupport\__feature__.py", line 142, in _import
    return original_import(name, *args, **kwargs)
Am I making a stupid mistake here? I appreciate any pointers in advance.

(Running on Windows)
User avatar
HakanSeven12
Veteran
Posts: 1481
Joined: Wed Feb 06, 2019 10:30 pm

Re: Civil engineering feature implementation (Transportation Engineering)

Post by HakanSeven12 »

Add your system informations please
jman
Posts: 4
Joined: Tue May 04, 2021 7:49 pm

Re: Civil engineering feature implementation (Transportation Engineering)

Post by jman »

See system information below:

OS: Windows 10 Version 2004
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.24276 (Git)
Build type: Release
Branch: releases/FreeCAD-0-19
Hash: a88db11e0a908f6e38f92bfc5187b13ebe470438
Python version: 3.8.6+
Qt version: 5.15.1
Coin version: 4.0.1
OCC version: 7.5.0
Locale: English/United Kingdom (en_GB)

Thanks again.
balrobs
Posts: 449
Joined: Fri Apr 24, 2020 8:58 pm

Re: Civil engineering feature implementation (Transportation Engineering)

Post by balrobs »

Hi HakanSeven12,
recently I stumbled across a strange FreeCAD behavior ... see following thread:
[Draft] Issue entering point in 3D view
I was wondering if the issue is related to Draft WB or to Trails WB?
Do you have any idea?
Thanks for your valuable help :)
Post Reply