Skip to content

Commit 1fc6fd2

Browse files
butlerpdjellybean2004
authored andcommitted
Merge pull request #731 from SasView/ticket-729-fibonacci-misssing
Tell pyinstaller to include special/fibonacci.py
1 parent 74b804d commit 1fc6fd2

3 files changed

Lines changed: 12 additions & 6 deletions

File tree

doc/genapi.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,8 @@ def genfiles(package, package_name, modules, dir='api'):
9191
('sasview_model', 'Sasview interface'),
9292
('sesans', 'SESANS calculation routines'),
9393
('special', 'Special functions library'),
94+
# Deprecate use of Fibonacci integration
95+
#('special.fibonacci', 'Fibonacci spiral spherical integration'),
9496
('weights', 'Distribution functions'),
9597
]
9698
package = 'sasmodels'

sasmodels/__pyinstaller/hook-sasmodels.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
"sasmodels.list_pars",
2525
"sasmodels.multiscat",
2626
"sasmodels.special",
27+
"sasmodels.special.fibonacci",
2728
"sasmodels.models.two_yukawa",
2829
]
2930
module_collection_mode = "py"

sasmodels/special/fibonacci.py

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,14 @@ def fibonacci_sphere(npoints_fibonacci: int):
1818
"""
1919
Generates npoints quasi-uniformly distributed on the unit sphere
2020
in Cartesian coordinates (x,y,z) and their associated weights.
21-
Parameters
22-
----------
21+
22+
**Parameters**
23+
2324
npoints : int
2425
Number of points to generate.
25-
Returns
26-
-------
26+
27+
**Returns**
28+
2729
points : ndarray, shape (npoints, 3)
2830
Cartesian coordinates of the points on the unit sphere.
2931
weights : ndarray, shape (npoints,)
@@ -45,8 +47,9 @@ def fibonacci_sphere(npoints_fibonacci: int):
4547
def plot_fibonacci_sphere(npoints_fibonacci=500, figsize=(7, 7)):
4648
"""
4749
3D representation of Fibonacci points on the unit sphere.
48-
Parameters
49-
----------
50+
51+
**Parameters**
52+
5053
npoints : int
5154
Number of points to generate and display.
5255
figsize : tuple

0 commit comments

Comments
 (0)