Skip to content

Commit 7fd2546

Browse files
author
andrewtliew
committed
Merge remote-tracking branch 'origin/master'
# Conflicts: # src/compas/numerical/solvers/ga.py
2 parents 8a4970d + 88f3e07 commit 7fd2546

File tree

26 files changed

+136
-480
lines changed

26 files changed

+136
-480
lines changed

src/compas/com/matlab_/engine.py

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,8 @@ def __init__(self, message=None):
2727

2828

2929
class MatlabEngine(object):
30-
"""Communicate with Matlab through the MATLAB engine.
30+
"""Communicate with Matlab through the MATLAB engine [mathworks2017a]_, [mathworks2017b]_,
31+
[mathworks2017c]_, [mathworks2017d]_, [mathworks2017e]_.
3132
3233
Attributes
3334
----------
@@ -43,14 +44,6 @@ class MatlabEngine(object):
4344
>>> matlab.engine.isprime(37)
4445
True
4546
46-
References
47-
----------
48-
* `MATLAB Engine API for Python <https://ch.mathworks.com/help/matlab/matlab-engine-for-python.html>`_
49-
* `Pass Data to MATLAB from Python <https://ch.mathworks.com/help/matlab/matlab_external/pass-data-to-matlab-from-python.html>`_
50-
* `Use MATLAB Arrays in Python <https://ch.mathworks.com/help/matlab/matlab_external/use-matlab-arrays-in-python.html>`_
51-
* `Use MATLAB Engine Workspace in Python <https://ch.mathworks.com/help/matlab/matlab_external/use-the-matlab-engine-workspace-in-python.html>`_
52-
* `Call MATLAB Functions from Python <https://ch.mathworks.com/help/matlab/matlab_external/call-matlab-functions-from-python.html>`_
53-
5447
"""
5548

5649
def __init__(self):

src/compas/datastructures/volmesh/volmesh.py

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,8 @@ class VolMesh(FromToData,
6666
6767
Volumetric meshes are 3-mainfold, cellular structures.
6868
69-
The implementation of ``VolMesh`` is based on the notion of *x-maps* [xmaps]
70-
and the concepts behind the *OpenVolumeMesh* library [ovm].
69+
The implementation of ``VolMesh`` is based on the notion of *x-maps*
70+
and the concepts behind the *OpenVolumeMesh* library [vci2016]_.
7171
In short, we add an additional entity compared to polygonal meshes,
7272
the *cell*, and relate cells not through *half-edges*, but through a combination
7373
of *half-faces* and *planes*. Each cell consists of a series of vertex pairs,
@@ -92,7 +92,7 @@ class VolMesh(FromToData,
9292
halffaces.
9393
``self.cell[ckey][u][v] -> fkey``
9494
halfface : dict
95-
The halffaces of the volmesh. Each halfface is represented by
95+
The halffaces of the volmesh. Each halfface is represented by
9696
``self.halfface[fkey] -> vertex cycle``
9797
plane : dict
9898
The planes of the volmesh. Every plane is uniquely defined by three
@@ -104,11 +104,6 @@ class VolMesh(FromToData,
104104
pointing at the cells of the volmesh.
105105
``self.plane[u][v][w] -> ckey``.
106106
107-
References
108-
----------
109-
.. [xmaps] xxx
110-
.. [ovm] `Open Volum Mesh <http://www.openvolumemesh.org>`_
111-
112107
"""
113108

114109
def __init__(self):
@@ -888,5 +883,5 @@ def scale(self, factor=1.0):
888883

889884
viewer.setup()
890885

891-
viewer.camera.zoom_out(5)
886+
viewer.camera.zoom_out(5)
892887
viewer.show()

src/compas/files/obj.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ def __init__(self, filepath, remote=False, precision=None):
4040

4141

4242
class OBJReader(object):
43-
"""Read the contents of an *obj* file.
43+
"""Read the contents of an *obj* file [Bourke]_.
4444
4545
Parameters:
4646
filepath (str): Path to the file.
@@ -61,9 +61,6 @@ class OBJReader(object):
6161
curves2 (list): Curves
6262
surfaces (list): Surfaces
6363
64-
References:
65-
http://paulbourke.net/dataformats/obj/
66-
6764
"""
6865

6966
def __init__(self, filepath, remote=False):

src/compas/geometry/__init__.py

Lines changed: 4 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -71,15 +71,10 @@
7171
7272
Vector
7373
Point
74-
Circle
7574
Line
76-
Frame
77-
Plane
7875
Polyline
7976
Polygon
8077
Polyhedron
81-
Spline
82-
Surface
8378
8479
.. autosummary::
8580
:toctree: generated/
@@ -183,22 +178,14 @@
183178
:toctree: generated/
184179
:nosignatures:
185180
186-
angle_smallest_points
187-
angle_smallest_points_xy
188-
angle_smallest_points_degrees
189-
angle_smallest_points_degrees_xy
190-
angle_smallest_vectors
191-
angle_smallest_vectors_xy
192-
angle_smallest_vectors_degrees
193-
angle_smallest_vectors_degrees_xy
181+
angle_points
182+
angle_points_xy
183+
angle_vectors
184+
angle_vectors_xy
194185
angles_points
195186
angles_points_xy
196-
angles_points_degrees
197-
angles_points_degrees_xy
198187
angles_vectors
199188
angles_vectors_xy
200-
angles_vectors_degrees
201-
angles_vectors_degrees_xy
202189
203190
204191
**Average**
@@ -356,7 +343,6 @@
356343
reflect_line_triangle
357344
rotate_points
358345
rotate_points_xy
359-
rotate_points_degrees
360346
scale_points
361347
translate_lines
362348
translate_lines_xy

src/compas/geometry/algorithms/bestfit.py

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929

3030

3131
def bestfit_plane(points):
32-
"""Fit a plane to a list of (more than three) points.
32+
"""Fit a plane to a list of (more than three) points [Ernerfeldt2015]_.
3333
3434
Parameters
3535
----------
@@ -41,10 +41,6 @@ def bestfit_plane(points):
4141
plane : tuple
4242
Base point and normal vector (normalized).
4343
44-
References
45-
----------
46-
http://www.ilikebigbits.com/blog/2015/3/2/plane-from-points
47-
4844
Warning
4945
-------
5046
This method will minimize the squares of the residuals as perpendicular
@@ -210,7 +206,7 @@ def bestfit_plane_numpy4(points):
210206

211207

212208
def bestfit_circle_numpy(points):
213-
"""Fit a circle through a set of points.
209+
"""Fit a circle through a set of points [Scipya]_.
214210
215211
Warning
216212
-------
@@ -233,11 +229,6 @@ def bestfit_circle_numpy(points):
233229
234230
#
235231
236-
237-
References
238-
----------
239-
* http://scipy-cookbook.readthedocs.io/items/Least_Squares_Circle.html
240-
241232
"""
242233
from numpy import sqrt
243234
from numpy import mean

src/compas/geometry/algorithms/hull.py

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525

2626

2727
def convex_hull(points):
28-
"""Construct convex hull for a set of points.
28+
"""Construct convex hull for a set of points [githubgist_a]_.
2929
3030
Parameters
3131
----------
@@ -77,9 +77,6 @@ def convex_hull(points):
7777
show_vertices = False,
7878
show_edges = False)
7979
80-
References
81-
----------
82-
* https://gist.github.com/anonymous/5184ba0bcab21d3dd19781efd3aae543
8380
8481
"""
8582
def _normal_face(face):
@@ -118,7 +115,7 @@ def _add_point(hull, p):
118115

119116

120117
def convex_hull_xy(points):
121-
"""Computes the convex hull of a set of 2D points.
118+
"""Computes the convex hull of a set of 2D points [wikibooks2017]_.
122119
123120
Note
124121
----
@@ -139,9 +136,6 @@ def convex_hull_xy(points):
139136
XY(Z) coordinates of vertices of the convex hull in counter-clockwise order,
140137
starting from the vertex with the lexicographically smallest coordinates.
141138
142-
References
143-
----------
144-
* https://en.wikibooks.org/wiki/Algorithm_Implementation/Geometry/Convex_hull/Monotone_chain
145139
146140
"""
147141

src/compas/geometry/algorithms/interpolation.py

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
def discrete_coons_patch(ab, bc, dc, ad):
2424
"""Creates a coons patch from a set of four or three boundary
25-
polylines (ab, bc, dc, ad).
25+
polylines (ab, bc, dc, ad) [wikipedia2017]_, [ferreol2013]_.
2626
2727
Direction and order of polylines::
2828
@@ -61,11 +61,6 @@ def discrete_coons_patch(ab, bc, dc, ad):
6161
--------
6262
* :func:`compas.datastructures.mesh_cull_duplicate_vertices`
6363
64-
References
65-
----------
66-
* https://en.wikipedia.org/wiki/Coons_patch
67-
* https://www.mathcurve.com/surfaces/patchcoons/patchcoons.shtml
68-
6964
"""
7065
if not ab:
7166
ab = [ad[0]] * len(dc)

0 commit comments

Comments
 (0)