1 write to Host
Microsoft.ML.TorchSharp (1)
AutoFormerV2\ObjectDetectionTrainer.cs (1)
137
Host
= Contracts.CheckRef(env, nameof(env)).Register(nameof(ObjectDetectionTrainer));
17 references to Host
Microsoft.ML.TorchSharp (17)
AutoFormerV2\ObjectDetectionTrainer.cs (17)
175
using (var ch =
Host
.Start("TrainModel"))
176
using (var pch =
Host
.StartProgressChannel("Training model"))
191
Host
.CheckAlive();
192
trainer.Train(
Host
, input, pch);
197
transformer = new ObjectDetectionTransformer(
Host
, Option, trainer.Model, new DataViewSchema.DetachedColumn(labelCol.Value));
227
Device = TorchUtils.InitializeDevice(Parent.
Host
);
240
Device = TorchUtils.InitializeDevice(Parent.
Host
);
275
var destDir = Path.Combine(((IHostEnvironmentInternal)Parent.
Host
).TempFilePath, "mlnet");
283
using (var ch = (Parent.
Host
as IHostEnvironment).Start("Ensuring model file is present."))
285
var ensureModel = ResourceManagerUtils.Instance.EnsureResourceAsync(Parent.
Host
, ch, ModelUrl, destFileName, destDir, timeout);
454
Host
.CheckValue(inputSchema, nameof(inputSchema));
495
throw
Host
.ExceptSchemaMismatch(nameof(inputSchema), "label", Option.LabelColumnName);
497
throw
Host
.ExceptSchemaMismatch(nameof(inputSchema), "label", Option.LabelColumnName,
501
throw
Host
.ExceptSchemaMismatch(nameof(inputSchema), "BoundingBox", Option.BoundingBoxColumnName);
503
throw
Host
.ExceptSchemaMismatch(nameof(inputSchema), "BoundingBox", Option.BoundingBoxColumnName,
507
throw
Host
.ExceptSchemaMismatch(nameof(inputSchema), "Image", Option.ImageColumnName);
509
throw
Host
.ExceptSchemaMismatch(nameof(inputSchema), "Image", Option.ImageColumnName,