Note
Go to the end to download the full example code.
Support Optimization Comparison#
Comparing Durech and Kaasalainen’s light curve inversion code to mine

Elapsed time: 2.19e-01 seconds
import numpy as np
import pyvista as pv
import mirage as mr
num = 100
ns = mr.spiral_sample_sphere(num).reshape(-1, 3)
ns = ns[np.random.permutation(num), :]
az = np.random.random(num) ** 2
egi = ns * az[:, None]
egi -= np.sum(egi, axis=0) / num
ns = mr.hat(egi)
mr.tic()
obj = mr.construct_mesh_from_egi(egi, implementation='fortran')
mr.toc()
pl = pv.Plotter()
pl.add_mesh(obj._mesh)
pl.show()
Total running time of the script: (0 minutes 0.329 seconds)