Change to the Normalized Pixel Percentage Formula

This commit is contained in:
2022-09-22 23:39:58 -07:00
parent 192d2ad776
commit fb1c68e1f5
27 changed files with 426 additions and 451 deletions

View File

@ -28,21 +28,6 @@ internal abstract class Face
return result;
}
internal static List<Models.Face> GetVerifiedFaces(int locationDigits, int locationFactor, List<Models.Face> faces)
{
List<Models.Face> results = new();
foreach (Models.Face face in faces)
{
if (face.Location?.NormalizedPixelPercentage is null)
results.Add(face);
else if (face.Location.NormalizedPixelPercentage.ToString() == ILocation.GetRightPadded(locationDigits, face.Location.NormalizedPixelPercentage.Value))
results.Add(face);
else
results.Add(new(face, face.Location, locationDigits, locationFactor, faces.Count));
}
return results;
}
private static JsonElement[] GetJsonElements(string jsonFileFullName)
{
string json = GetJson(jsonFileFullName);