21 references to Assert
Microsoft.ML.Core (21)
Data\IFileHandle.cs (3)
113
Contracts.
Assert
(false, "Closing a SimpleFileHandle write stream failed!");
128
Contracts.
Assert
(false, "Closing a SimpleFileHandle read stream failed!");
145
Contracts.
Assert
(false, "Deleting a SimpleFileHandle physical file failed!");
Data\RoleMappedSchema.cs (1)
170
Contracts.
Assert
(!schema[info.Index].IsHidden, "How did a hidden column sneak in?");
Utilities\BigArray.cs (1)
93
Contracts.
Assert
(BlockSize > 1 && (BlockSize & (BlockSize - 1)) == 0, "Block size is not a power of two.");
Utilities\BitUtils.cs (3)
177
Contracts.
Assert
(0 <= ibit && ibit < CbitUint, "UMaskBelow is designed to work for 0 <= ibit < 32");
184
Contracts.
Assert
(0 <= ibit && ibit < CbitUlong, "UMaskBelowEx is designed to work for 0 <= ibit < 64");
193
Contracts.
Assert
(0 <= ibit && ibit < CbitUlong, "UuMaskBelow is designed to work for 0 <= ibit < 64");
Utilities\Contracts.cs (1)
74
Contracts.
Assert
(false, "Format string arg mismatch: " + ex.Message);
Utilities\FixedSizeQueue.cs (5)
25
Contracts.
Assert
(capacity > 0, "Array capacity should be greater than zero");
96
Contracts.
Assert
(_count != 0, "Array is empty");
103
Contracts.
Assert
(_count != 0, "Array is empty");
110
Contracts.
Assert
(_count != 0, "Array is empty");
122
Contracts.
Assert
(_count != 0, "Array is empty");
Utilities\HybridMemoryStream.cs (1)
175
Contracts.
Assert
(tmp, "TryGetBuffer failed in HybridMemoryStream");
Utilities\MathUtils.cs (1)
26
Contracts.
Assert
(false, "Bad use of ToFloat");
Utilities\MatrixTransposeOps.cs (2)
33
Contracts.
Assert
(src != dst, "Transpose in place not supported");
84
Contracts.
Assert
(src != dst, "Transpose in place not supported");
Utilities\SupervisedBinFinder.cs (2)
108
Contracts.
Assert
(boundaries.Length == 1 && boundaries[0] == 0 || boundaries[0] > 0, "boundaries are exclusive, can't have 0");
186
Contracts.
Assert
(boundaries.Length == 1 && boundaries[0] == 0 || boundaries[0] > 0, "boundaries are exclusive, can't have 0");
Utilities\Utils.cs (1)
721
Contracts.
Assert
(length >= 0, "Length can't be negative");