3D Surface - Face Selection (New feature) [Merged]
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Be nice to others! Respect the FreeCAD code of conduct!
Re: 3D Surface - Face Selection (New feature) [Merged]
Use the current from the site you linked.
And get your quoting of your own messages right.
And get your quoting of your own messages right.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
Re: 3D Surface - Face Selection (New feature) [Merged]
Please keep your dev version as updated as possible. You are way behind. Please download latest and re-test.
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
-
- Posts: 24
- Joined: Tue Apr 17, 2018 12:57 pm
Re: 3D Surface - Face Selection (New feature) [Merged]
...sorry guys...I have foggoten to copy PathSurfaceGui...
It work well!!!!!!
thank you very much!!!!!
It work well!!!!!!
thank you very much!!!!!
Re: 3D Surface - Face Selection (New feature) [Merged]
I've been working on some improvements for processing time on this. If anyone wants to try it out it's at this branch https://github.com/etrombly/FreeCAD/tre ... rface_perf . You'll need to compile as I added in openmp for some parallel processing. I've only tested on linux, so some windows and mac testing would be appreciated.
-
- Posts: 24
- Joined: Tue Apr 17, 2018 12:57 pm
Re: 3D Surface - Face Selection (New feature) [Merged]
Hello Guys,
Maybe any ideas why I still have Zigzag with ups and downs?
...how to set it up without?
Maybe any ideas why I still have Zigzag with ups and downs?
...how to set it up without?
- Attachments
-
- 3D_Face.png (288.24 KiB) Viewed 1817 times
-
- Posts: 24
- Joined: Tue Apr 17, 2018 12:57 pm
Re: 3D Surface - Face Selection (New feature) [Merged]
...here is the file
- Attachments
-
- 3d face.FCStd
- (32.83 KiB) Downloaded 45 times
Re: 3D Surface - Face Selection (New feature) [Merged]
Hi All, Hi Russ,
I found little bugs in the new PathSurface.py code.
There is wrong comments on near the begining of the GCode output like this:
=> From line 3 to 7, the open parenthesis are missing and there is no comment in line 7.
I think the bug is comming from line 390 to 398 in PathSurface.py, when you plan to construct a multi-lines comment and pass it to the Path.Command() object.
Comments can't be multi-lines in GCode.
Replacing lines 390 to 398 in PathSurface.py with those ones can correct the problem:
In addition, the G0 GCode does not have to have feedrate parameter, like I can see in lines 8,9 and 11 of PathSurface output...
Perhaps will it be fine to correct this.
Thanks again for your great job,
@++;
Gauthier.
I found little bugs in the new PathSurface.py code.
There is wrong comments on near the begining of the GCode output like this:
Code: Select all
(Surface001)
(Surface001)
Tool type: EndMill)
Compensated Tool Path. Diameter: 5.0)
Sample interval: 0.1)
Step over %: 60)
)
G0 F0.000000 Z5.000000
G0 F0.000000 X0.000000 Y0.000000
(Beginning of Single-pass layer.)
G0 F0.000000 X-0.500000 Y2.000000
(Begin step 0.)
(part 1.)
G1 X-0.500000 Y2.000000 Z0.300000 F300.000000
...
I think the bug is comming from line 390 to 398 in PathSurface.py, when you plan to construct a multi-lines comment and pass it to the Path.Command() object.
Comments can't be multi-lines in GCode.
Replacing lines 390 to 398 in PathSurface.py with those ones can correct the problem:
Code: Select all
if obj.Comment != '':
self.commandlist.append(Path.Command('N ({})'.format(str(obj.Comment)), {}))
self.commandlist.append(Path.Command('N ({})'.format(obj.Label), {}))
self.commandlist.append(Path.Command('N (Tool type: {})'.format(str(obj.ToolController.Tool.ToolType)), {}))
self.commandlist.append(Path.Command('N (Compensated Tool Path. Diameter: {})'.format(str(obj.ToolController.Tool.Diameter)), {}))
self.commandlist.append(Path.Command('N (Sample interval: {})'.format(str(obj.SampleInterval.Value)), {}))
self.commandlist.append(Path.Command('N (Step over %: {})'.format(str(obj.StepOver)), {}))
Perhaps will it be fine to correct this.
Thanks again for your great job,
@++;
Gauthier.
-
- Posts: 991
- Joined: Wed Mar 27, 2019 10:45 am
Re: 3D Surface - Face Selection (New feature) [Merged]
First of all, I just had some time to review all the new options in the Data tab for 3D surface and they are all quite clear. I like it.
I especially appreciate that you brought back up to the GUI Linear Deflection and Angular Deflection, as well as their respective tooltips indicating the processing time cost associated. Real nice.
Issue found with the tool tips: "Smaller values yield a finer, more accurate the mesh." for both Angular and Linear Deflection. Should be "Smaller values yield a finer, more accurate mesh".
Now for the other issues:
I seem to have trouble with the Circular (and CIrcular ZigZag) patterns. See file attached. They compute fine on the flat surface in-between the half spheres but they crash on the half spheres themselves.
The issue seems to be a math error. Here the associated report:
Hopefully this helps you figure out what's wrong (the error may be sitting between the steering wheel and the driver's seat...)
EDIT: I started playing with the center used for the circular calculation just in case i was accidentally asking for something impossible to the algo, only XminYmin really worked. The result is shall I say interesting: OS: Windows 10 (10.0)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.20276 (Git)
Build type: Release
Branch: master
Hash: 3a0d9e8c514c163be0b750dd75bb4f2afe4f94f1
Python version: 3.6.8
Qt version: 5.12.1
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: English/Switzerland (en_CH)
I especially appreciate that you brought back up to the GUI Linear Deflection and Angular Deflection, as well as their respective tooltips indicating the processing time cost associated. Real nice.
Issue found with the tool tips: "Smaller values yield a finer, more accurate the mesh." for both Angular and Linear Deflection. Should be "Smaller values yield a finer, more accurate mesh".
Now for the other issues:
I seem to have trouble with the Circular (and CIrcular ZigZag) patterns. See file attached. They compute fine on the flat surface in-between the half spheres but they crash on the half spheres themselves.
The issue seems to be a math error. Here the associated report:
Code: Select all
Begin 3D Surface operation...
PathSurface.WARNING: Final Depth might need to be lower. Internal features detected in Face2.
Traceback (most recent call last):
File "C:\Program Files\FreeCAD019\FreeCAD_0.19.20276_x64_LP_12.1.2_PY3QT5-WinVS2015\Mod\Path\PathScripts\PathUtils.py", line 59, in new_function
res = function(*args, **kwargs)
File "C:\Program Files\FreeCAD019\FreeCAD_0.19.20276_x64_LP_12.1.2_PY3QT5-WinVS2015\Mod\Path\PathScripts\PathOp.py", line 513, in execute
result = self.opExecute(obj) # pylint: disable=assignment-from-no-return
File "C:\Program Files\FreeCAD019\FreeCAD_0.19.20276_x64_LP_12.1.2_PY3QT5-WinVS2015\Mod\Path\PathScripts\PathSurface.py", line 518, in opExecute
CMDS.extend(self._processCutAreas(JOB, obj, m, FACES[m], VOIDS[m]))
File "C:\Program Files\FreeCAD019\FreeCAD_0.19.20276_x64_LP_12.1.2_PY3QT5-WinVS2015\Mod\Path\PathScripts\PathSurface.py", line 1568, in _processCutAreas
final.extend(self._processPlanarOp(JOB, obj, mdlIdx, COMP, 0))
File "C:\Program Files\FreeCAD019\FreeCAD_0.19.20276_x64_LP_12.1.2_PY3QT5-WinVS2015\Mod\Path\PathScripts\PathSurface.py", line 1657, in _processPlanarOp
geoScan = self._planarPerformOclScan(obj, pdc, pathGeom, offsetPoints=False)
File "C:\Program Files\FreeCAD019\FreeCAD_0.19.20276_x64_LP_12.1.2_PY3QT5-WinVS2015\Mod\Path\PathScripts\PathSurface.py", line 1961, in _planarPerformOclScan
PNTSET = self._pathGeomToArcPointSet(obj, pathGeom)
File "C:\Program Files\FreeCAD019\FreeCAD_0.19.20276_x64_LP_12.1.2_PY3QT5-WinVS2015\Mod\Path\PathScripts\PathSurface.py", line 2369, in _pathGeomToArcPointSet
tolrncAng = math.asin(space/rad)
<class 'ValueError'>: math domain error
1534.75 <App> Document.cpp(3715): Failed to recompute Unnamed#Surface: math domain error
Recompute failed! Please check report view.
EDIT: I started playing with the center used for the circular calculation just in case i was accidentally asking for something impossible to the algo, only XminYmin really worked. The result is shall I say interesting: OS: Windows 10 (10.0)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.20276 (Git)
Build type: Release
Branch: master
Hash: 3a0d9e8c514c163be0b750dd75bb4f2afe4f94f1
Python version: 3.6.8
Qt version: 5.12.1
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: English/Switzerland (en_CH)
Last edited by RatonLaveur on Fri Mar 27, 2020 5:55 pm, edited 1 time in total.
-
- Posts: 991
- Joined: Wed Mar 27, 2019 10:45 am
Re: 3D Surface - Face Selection (New feature) [Merged]
Unfortunately I am only a windows user, but I've been looking at your code and it seems cleaner indeed. Do you have an idea how much improvement you will be able to squeeze through this project? 10% faster? 100%?etrombly wrote: ↑Fri Mar 27, 2020 2:12 am I've been working on some improvements for processing time on this. If anyone wants to try it out it's at this branch https://github.com/etrombly/FreeCAD/tre ... rface_perf . You'll need to compile as I added in openmp for some parallel processing. I've only tested on linux, so some windows and mac testing would be appreciated.
Re: 3D Surface - Face Selection (New feature) [Merged]
Good morning,
Investigating your file and the 3D Surface operation, I found a few things.
The current solution:
Russ
OS: Windows 10 (10.0)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.20286 +23 (Git)
Build type: Release
Branch: Surface_Waterline_Split
Hash: 6ae6899c9e30c9315f4694d4f8f4aa71fa5335ee
Python version: 3.6.8
Qt version: 5.12.1
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: English/United States (en_US)
giedrius9999 wrote: ↑Fri Mar 27, 2020 2:41 pm Hello Guys,
Maybe any ideas why I still have Zigzag with ups and downs?
...how to set it up without?
Investigating your file and the 3D Surface operation, I found a few things.
The current solution:
- Change the `BoundBox` property to `Stock`
- Toggle the `Optimize Step Over Transitions` to `True`
- Using the `Default Tool` in some cases will cause weird behaviors in some operations. I don't know if this has bee fixed completely in PathWB. So, just be aware. I suggest you load a tool and its tool controller for each Job, or set up a Job Template with the tool and controller loaded.
- Generally, when we push new features to the PathWB, we need them to produce as safe, reliable, and accurate paths as reasonably possible. What that means for 3D Surface is that for each of the patterns, the tool will raise to SafeHeight after each break in the path, whether mid-line or between stepover transitions. While not ideal, or necessarily desirable, it keeps(should keep) your material and machine from breaking. So, be aware of the `Surface Optimization` group of properties in the Data tab. For all cut patterns, toggle the `Optimize Step Over Transitions` property to `True`. This will attempt to keep the cutter down on these zig-zags as well as other breaks or stepovers and attempt to minimize transitional paths as best possible by the algorithm.
- I think what you are reporting is a bug because the intended behavior after applying the `Optimize Step Over Transitions` feature is that it should keep the ZigZag down in this case, without the need to change `BoundBox` to `Stock`. I think I might need to adjust the tolerances at play. I will take a look.
- As an additional plug here, 3D Surface is the only (that I am aware of) operation in the PathWB capable of producing a 3D profile operation. So, I threw in a second 3D Surface operation to your file and set `ProfileEdges' to 'Only'. This cleans up the edges of your 3D top surface. I did find a transitional bug here with it set to `First` or `Last`. I need to fix the transition from clearing path to profile path.
Russ
OS: Windows 10 (10.0)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.20286 +23 (Git)
Build type: Release
Branch: Surface_Waterline_Split
Hash: 6ae6899c9e30c9315f4694d4f8f4aa71fa5335ee
Python version: 3.6.8
Qt version: 5.12.1
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: English/United States (en_US)
- Attachments
-
- 3d face_A-1.png (196.37 KiB) Viewed 1798 times
-
- 3d face_A-2.png (189.19 KiB) Viewed 1798 times