@@ -251,7 +251,7 @@ def __str__(self) -> str:
251251
252252 def select (self , xy : ArrayLike ) -> int :
253253 """
254- Return the cluster index appropriate for the given *CIE xy*
254+ Determine the cluster index appropriate for the specified *CIE xy*
255255 coordinates.
256256
257257 Parameters
@@ -294,7 +294,7 @@ def select(self, xy: ArrayLike) -> int:
294294
295295 def cluster (self , xy : ArrayLike ) -> Tuple [NDArrayFloat , NDArrayFloat ]:
296296 """
297- Return the basis functions and dataset mean for the given *CIE xy*
297+ Retrieve the basis functions and dataset mean for the specified *CIE xy*
298298 coordinates.
299299
300300 Parameters
@@ -367,7 +367,7 @@ def read(self, path: str | PathLike) -> None:
367367
368368 def write (self , path : str | PathLike ) -> None :
369369 """
370- Write the dataset to an *.npz* file at given path.
370+ Write the dataset to an *.npz* file at specified path.
371371
372372 Parameters
373373 ----------
@@ -444,7 +444,7 @@ def XYZ_to_sd_Otsu2018(
444444 clip : bool = True ,
445445) -> SpectralDistribution :
446446 """
447- Recover the spectral distribution of given *CIE XYZ* tristimulus values
447+ Recover the spectral distribution of specified *CIE XYZ* tristimulus values
448448 using *Otsu et al. (2018)* method.
449449
450450 Parameters
@@ -786,7 +786,7 @@ def __str__(self) -> str:
786786
787787 def __len__ (self ) -> int :
788788 """
789- Return the number of colours in the data.
789+ Determine the number of colours in the data.
790790
791791 Returns
792792 -------
@@ -798,8 +798,8 @@ def __len__(self) -> int:
798798
799799 def origin (self , i : int , direction : int ) -> float :
800800 """
801- Return the origin *CIE x* or *CIE y* chromaticity coordinate for given
802- index and direction.
801+ Retrieve the origin *CIE x* or *CIE y* chromaticity coordinate for
802+ specified index and direction.
803803
804804 Parameters
805805 ----------
@@ -828,7 +828,7 @@ def origin(self, i: int, direction: int) -> float:
828828
829829 def partition (self , axis : PartitionAxis ) -> Tuple [Data_Otsu2018 , Data_Otsu2018 ]:
830830 """
831- Partition the data using given partition axis.
831+ Partition the data using specified partition axis.
832832
833833 Parameters
834834 ----------
@@ -904,7 +904,7 @@ def PCA(self) -> None:
904904
905905 def reconstruct (self , XYZ : ArrayLike ) -> SpectralDistribution :
906906 """
907- Reconstruct the reflectance for the given *CIE XYZ* tristimulus
907+ Reconstruct the reflectance for the specified *CIE XYZ* tristimulus
908908 values.
909909
910910 Parameters
@@ -947,7 +947,7 @@ def reconstruct(self, XYZ: ArrayLike) -> SpectralDistribution:
947947
948948 def reconstruction_error (self ) -> float :
949949 """
950- Return the reconstruction error of the data. The error is computed by
950+ Compute the reconstruction error of the data. The error is computed by
951951 reconstructing the reflectances for the reference *CIE XYZ* tristimulus
952952 values using PCA and, comparing the reconstructed reflectances against
953953 the reference reflectances.
@@ -1076,7 +1076,7 @@ def row(self) -> Tuple[float, float, Self, Self]:
10761076
10771077 def split (self , children : Sequence [Self ], axis : PartitionAxis ) -> None :
10781078 """
1079- Convert the leaf node into an inner node using given children and
1079+ Convert the leaf node into an inner node using specified children and
10801080 partition axis.
10811081
10821082 Parameters
@@ -1110,7 +1110,7 @@ def minimise(
11101110 Returns
11111111 -------
11121112 :class:`tuple`
1113- Tuple of tuple of nodes created by splitting a node with a given
1113+ Tuple of tuple of nodes created by splitting a node with a specified
11141114 partition, partition axis, i.e., the horizontal or vertical line,
11151115 partitioning the 2D space in two half-planes and partition error.
11161116 """
@@ -1172,7 +1172,7 @@ def minimise(
11721172
11731173 def leaf_reconstruction_error (self ) -> float :
11741174 """
1175- Return the reconstruction error of the node data. The error is
1175+ Compute the reconstruction error of the node data. The error is
11761176 computed by reconstructing the reflectances for the data reference
11771177 *CIE XYZ* tristimulus values using PCA and, comparing the reconstructed
11781178 reflectances against the data reference reflectances.
@@ -1584,7 +1584,7 @@ def to_dataset(self) -> Dataset_Otsu2018:
15841584 else :
15851585
15861586 def add_rows (node : Node_Otsu2018 , data : dict | None = None ) -> dict | None :
1587- """Add rows for given node and its children."""
1587+ """Add rows for specified node and its children."""
15881588
15891589 data = optional (data , {"rows" : [], "node_to_leaf_id" : {}, "leaf_id" : 0 })
15901590
0 commit comments