MantisBT
Mantis Bug Tracker Workflow

View Issue Details Jump to Notes ] Related Changesets ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0030874Community[OCCT] OCCT:Modeling Algorithmspublic2019-08-07 15:022019-09-02 18:00
Reporterdrazmyslovich 
Assigned Toapn 
PrioritynormalSeverityminor 
StatusverifiedResolutionfixed 
PlatformWindowsOSVC++ 2015OS Version64 bit
Product Version[OCCT] 7.4.0 
Target Version[OCCT] 7.5.0*Fixed in Version 
Summary0030874: Modeling Algorithms - GCPnts_TangentialDeflection inserts the points between nearby points
DescriptionGCPnts_TangentialDeflection is able to infinitely insert the points
Steps To ReproduceUnfortunately, I have no example curve to reproduce the problem.
TagsNo tags attached.
Test case numberNot needed
Attached Files

- Relationships

-  Notes
(0086065)
git (administrator)
2019-08-07 15:12

Branch CR30874 has been created by drazmyslovich.

SHA-1: 496afeb5eb2361cf34dc8162c9a0eda1af3f85b4


Detailed log of new commits:

Author: drazmyslovich
Date: Wed Aug 7 14:10:32 2019 +0200

    0030874: GCPnts_TangentialDeflection - check the points distance before inserting a new point in between
(0086066)
drazmyslovich (developer)
2019-08-07 15:13

The proposed solution is submitted, please, review
(0086073)
oan (developer)
2019-08-07 18:40

Dear Mikhail,

could you please manage the issue.
(0086083)
msv (developer)
2019-08-08 09:57

Dear Eugeny, please review it.
(0086184)
emv (developer)
2019-08-12 14:14

Hello Dima,

Is this bug reproduced on any of your data, confidential or public? Because, looking into the code I see that the points will not be inserted infinitely as you suggest. The conditions
if (umax - U1 > uTol && U2 - umax > uTol)
{
  if (P1.SquareDistance(MiddlePoint) > MinLen2 && P2.SquareDistance(MiddlePoint) > MinLen2)
  
{
    // insert point
  }
}

are actually stronger than yours.

However, I agree that early check such as you implemented should be inserted, but the criterion instead of gp::Resolution() should be uTol for parametric tolerance and MinLen2 for square distance between nearby points.
(0086263)
git (administrator)
2019-08-15 14:24

Branch CR30874 has been updated by drazmyslovich.

SHA-1: 33eb19e6143e3a4a66e576ebded5df20b651e524


Detailed log of new commits:

Author: drazmyslovich
Date: Thu Aug 15 13:22:23 2019 +0200

    0030874: Use uTol and MinLen2 values as threshold

(0086264)
drazmyslovich (developer)
2019-08-15 14:27

Dear Eugeny,

I have adjusted the code according to your comments.
I will try to find an example data to reproduce the original problem.

Regards,
Dima
(0086265)
git (administrator)
2019-08-15 14:33

Branch CR30874_1 has been created by emv.

SHA-1: eafdde15470f51ddcb369e338671b464abf4bfb6


Detailed log of new commits:

Author: drazmyslovich
Date: Wed Aug 7 15:10:32 2019 +0300

    0030874: GCPnts_TangentialDeflection inserts the points between nearby points
    
    Check the points distance before inserting a new point in between.
(0086266)
emv (developer)
2019-08-15 14:34

Hello Dima, thanks for the update. I have squashed the commits and going to initiate certification of the patch.
(0086269)
git (administrator)
2019-08-16 09:09

Branch CR30874_1 has been updated forcibly by emv.

SHA-1: 4e41a26ff42d07429eef7ce11712e2823257e77c
(0086270)
emv (developer)
2019-08-16 09:13

There was a misprint in the patch that has not been noticed, but tests revealed. Instead of condition U2-U1<uTol, there was U1-U2<uTol which was always true and points have never been inserted. I've corrected it and re-run the tests.
(0086278)
kgv (developer)
2019-08-16 13:32
edited on: 2019-08-16 13:33

> However, I agree that early check such as you implemented should be inserted,
Are you sure this is correct check for 3D points?

From my understanding, this might prevent inserting points on curve having a local splash - e.g. two checked points are indeed very close to each other, while point in the middle might have greater distance to both.

(0086279)
emv (developer)
2019-08-16 13:53

You are right, the check for 3D points is incorrect and should be removed. Let's keep only parametric check.
(0086280)
drazmyslovich (developer)
2019-08-16 14:02

Therefore I used in the original version gp::Resolution () as it helps to identify the points which are too close.
(0086282)
kgv (developer)
2019-08-16 14:13

> Therefore I used in the original version gp::Resolution ()
> as it helps to identify the points which are too close.
For degenerate cases it is still incorrect checked distance between 2 points - the check for a middle point should be done, and it uses larger tolerance than gp::Resolution().
(0086283)
drazmyslovich (developer)
2019-08-16 14:20

But if you have a degenerated case, then it makes no sense to proceed. Even worse if due to some other problems in generated case D0 will deliver a middle point, which is far away from the curve, then it will cause the algorithm to proceed instead of earlier bailing out.
(0086284)
kgv (developer)
2019-08-16 14:25

> But if you have a degenerated case, then it makes no sense to proceed.
GCPnts_TangentialDeflection is not supposed to hide geometry issues.
(0086290)
git (administrator)
2019-08-16 17:01

Branch CR30874_1 has been updated forcibly by emv.

SHA-1: 167464fbd4512e0a3b72faf4d29772d29f460561
(0086345)
git (administrator)
2019-08-20 07:31

Branch CR30874_1 has been updated forcibly by emv.

SHA-1: a71ec8aee31763182f18b530e82f21a9c45e5f03
(0086390)
emv (developer)
2019-08-22 07:30

Testing shows no regressions - http://jenkins-test-12.nnov.opencascade.com/view/CR30874-master-emv/view/COMPARE/ [^]
(0086422)
apn (administrator)
2019-08-22 20:36

Combination -
OCCT branch : CR30874_1
master SHA - a71ec8aee31763182f18b530e82f21a9c45e5f03
5f5b1aed1c6e139bbd34314eca77ae7abcd8895c
Products branch : master SHA - 32e882a7b3145a66baa739f965d275c822c0bd8a
was compiled on Linux, MacOS and Windows platforms and tested in optimize mode.

Number of compiler warnings:
No new/fixed warnings

Regressions/Differences/Improvements:
No regressions/differences

CPU differences:
Debian80-64:
OCCT
Total CPU difference: 16087.120000000043 / 16105.290000000065 [-0.11%]
Products
Total CPU difference: 10477.740000000053 / 10484.700000000048 [-0.07%]
Windows-64-VC14:
OCCT
Total CPU difference: 18243.75 / 18149.296875 [+0.52%]
Products
Total CPU difference: 12061.359375 / 12045.34375 [+0.13%]

Image differences :
No differences that require special attention

Memory differences :
No differences that require special attention
(0086628)
git (administrator)
2019-09-02 17:52

Branch CR30874 has been deleted by mnt.

SHA-1: 33eb19e6143e3a4a66e576ebded5df20b651e524
(0086629)
git (administrator)
2019-09-02 18:00

Branch CR30874_1 has been deleted by apn.

SHA-1: a71ec8aee31763182f18b530e82f21a9c45e5f03

- Related Changesets
occt: master 846245d4
Timestamp: 2019-08-07 12:10:32
Author: drazmyslovich
Committer: apn
Details ] Diff ]
0030874: Modeling Algorithms - GCPnts_TangentialDeflection inserts the points between nearby points

Check the points distance before inserting a new point in between.
mod - src/GCPnts/GCPnts_TangentialDeflection.pxx Diff ] File ]

- Issue History
Date Modified Username Field Change
2019-08-07 15:02 drazmyslovich New Issue
2019-08-07 15:02 drazmyslovich Assigned To => oan
2019-08-07 15:03 drazmyslovich Assigned To oan => drazmyslovich
2019-08-07 15:12 git Note Added: 0086065
2019-08-07 15:13 drazmyslovich Note Added: 0086066
2019-08-07 15:13 drazmyslovich Assigned To drazmyslovich => oan
2019-08-07 15:13 drazmyslovich Status new => resolved
2019-08-07 18:39 oan Category OCCT:Mesh => OCCT:Modeling Algorithms
2019-08-07 18:40 oan Assigned To oan => msv
2019-08-07 18:40 oan Note Added: 0086073
2019-08-08 09:57 msv Note Added: 0086083
2019-08-08 09:57 msv Assigned To msv => emv
2019-08-12 14:14 emv Note Added: 0086184
2019-08-12 14:14 emv Assigned To emv => drazmyslovich
2019-08-12 14:14 emv Status resolved => feedback
2019-08-12 15:09 msv Target Version 7.4.0 => 7.5.0*
2019-08-15 14:24 git Note Added: 0086263
2019-08-15 14:27 drazmyslovich Note Added: 0086264
2019-08-15 14:27 drazmyslovich Assigned To drazmyslovich => emv
2019-08-15 14:27 drazmyslovich Status feedback => resolved
2019-08-15 14:33 git Note Added: 0086265
2019-08-15 14:34 emv Note Added: 0086266
2019-08-15 18:57 kgv Summary GCPnts_TangentialDeflection inserts the points between nearby points => Modeling Algorithms - GCPnts_TangentialDeflection inserts the points between nearby points
2019-08-16 09:09 git Note Added: 0086269
2019-08-16 09:13 emv Note Added: 0086270
2019-08-16 13:32 kgv Note Added: 0086278
2019-08-16 13:33 kgv Note Edited: 0086278 View Revisions
2019-08-16 13:53 emv Note Added: 0086279
2019-08-16 14:02 drazmyslovich Note Added: 0086280
2019-08-16 14:13 kgv Note Added: 0086282
2019-08-16 14:20 drazmyslovich Note Added: 0086283
2019-08-16 14:25 kgv Note Added: 0086284
2019-08-16 17:01 git Note Added: 0086290
2019-08-20 07:31 git Note Added: 0086345
2019-08-22 07:30 emv Note Added: 0086390
2019-08-22 07:30 emv Assigned To emv => bugmaster
2019-08-22 07:30 emv Status resolved => reviewed
2019-08-22 20:36 apn Test case number => Not needed
2019-08-22 20:36 apn Note Added: 0086422
2019-08-22 20:36 apn Status reviewed => tested
2019-08-24 16:56 apn Changeset attached => occt master 846245d4
2019-08-24 16:56 apn Assigned To bugmaster => apn
2019-08-24 16:56 apn Status tested => verified
2019-08-24 16:56 apn Resolution open => fixed
2019-09-02 17:52 git Note Added: 0086628
2019-09-02 18:00 git Note Added: 0086629


Copyright © 2000 - 2019 MantisBT Team
Powered by Mantis Bugtracker