1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. AiVision
  5. getModel
Oracle Cloud Infrastructure v2.28.0 published on Thursday, Mar 27, 2025 by Pulumi

oci.AiVision.getModel

Explore with Pulumi AI

Oracle Cloud Infrastructure v2.28.0 published on Thursday, Mar 27, 2025 by Pulumi

This data source provides details about a specific Model resource in Oracle Cloud Infrastructure Ai Vision service.

Gets a Model by identifier

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";

const testModel = oci.AiVision.getModel({
    modelId: testModelOciAiVisionModel.id,
});
Copy
import pulumi
import pulumi_oci as oci

test_model = oci.AiVision.get_model(model_id=test_model_oci_ai_vision_model["id"])
Copy
package main

import (
	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/aivision"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := aivision.GetModel(ctx, &aivision.GetModelArgs{
			ModelId: testModelOciAiVisionModel.Id,
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Oci = Pulumi.Oci;

return await Deployment.RunAsync(() => 
{
    var testModel = Oci.AiVision.GetModel.Invoke(new()
    {
        ModelId = testModelOciAiVisionModel.Id,
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.AiVision.AiVisionFunctions;
import com.pulumi.oci.AiVision.inputs.GetModelArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        final var testModel = AiVisionFunctions.getModel(GetModelArgs.builder()
            .modelId(testModelOciAiVisionModel.id())
            .build());

    }
}
Copy
variables:
  testModel:
    fn::invoke:
      function: oci:AiVision:getModel
      arguments:
        modelId: ${testModelOciAiVisionModel.id}
Copy

Using getModel

Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

function getModel(args: GetModelArgs, opts?: InvokeOptions): Promise<GetModelResult>
function getModelOutput(args: GetModelOutputArgs, opts?: InvokeOptions): Output<GetModelResult>
Copy
def get_model(model_id: Optional[str] = None,
              opts: Optional[InvokeOptions] = None) -> GetModelResult
def get_model_output(model_id: Optional[pulumi.Input[str]] = None,
              opts: Optional[InvokeOptions] = None) -> Output[GetModelResult]
Copy
func GetModel(ctx *Context, args *GetModelArgs, opts ...InvokeOption) (*GetModelResult, error)
func GetModelOutput(ctx *Context, args *GetModelOutputArgs, opts ...InvokeOption) GetModelResultOutput
Copy

> Note: This function is named GetModel in the Go SDK.

public static class GetModel 
{
    public static Task<GetModelResult> InvokeAsync(GetModelArgs args, InvokeOptions? opts = null)
    public static Output<GetModelResult> Invoke(GetModelInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetModelResult> getModel(GetModelArgs args, InvokeOptions options)
public static Output<GetModelResult> getModel(GetModelArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: oci:AiVision/getModel:getModel
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

ModelId This property is required. string
unique Model identifier
ModelId This property is required. string
unique Model identifier
modelId This property is required. String
unique Model identifier
modelId This property is required. string
unique Model identifier
model_id This property is required. str
unique Model identifier
modelId This property is required. String
unique Model identifier

getModel Result

The following output properties are available:

AveragePrecision double
Average precision of the trained model
CompartmentId string
Compartment Identifier
ConfidenceThreshold double
Confidence ratio of the calculation
DefinedTags Dictionary<string, string>
Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
Description string
A short description of the model.
DisplayName string
Model Identifier, can be renamed
FreeformTags Dictionary<string, string>
Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
Id string
Unique identifier that is immutable on creation
IsQuickMode bool
If It's true, Training is set for recommended epochs needed for quick training.
LifecycleDetails string
A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in Failed state.
MaxTrainingDurationInHours double
The maximum duration in hours for which the training will run.
Metrics string
Complete Training Metrics for successful trained model
ModelId string
ModelType string
Type of the Model.
ModelVersion string
The version of the model
Precision double
Precision of the trained model
ProjectId string
The OCID of the project to associate with the model.
Recall double
Recall of the trained model
State string
The current state of the Model.
SystemTags Dictionary<string, string>
Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
TestImageCount int
Total number of testing Images
TestingDatasets List<GetModelTestingDataset>
The base entity for a Dataset, which is the input for Model creation.
TimeCreated string
The time the Model was created. An RFC3339 formatted datetime string
TimeUpdated string
The time the Model was updated. An RFC3339 formatted datetime string
TotalImageCount int
Total number of training Images
TrainedDurationInHours double
Total hours actually used for training
TrainingDatasets List<GetModelTrainingDataset>
The base entity for a Dataset, which is the input for Model creation.
ValidationDatasets List<GetModelValidationDataset>
The base entity for a Dataset, which is the input for Model creation.
AveragePrecision float64
Average precision of the trained model
CompartmentId string
Compartment Identifier
ConfidenceThreshold float64
Confidence ratio of the calculation
DefinedTags map[string]string
Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
Description string
A short description of the model.
DisplayName string
Model Identifier, can be renamed
FreeformTags map[string]string
Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
Id string
Unique identifier that is immutable on creation
IsQuickMode bool
If It's true, Training is set for recommended epochs needed for quick training.
LifecycleDetails string
A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in Failed state.
MaxTrainingDurationInHours float64
The maximum duration in hours for which the training will run.
Metrics string
Complete Training Metrics for successful trained model
ModelId string
ModelType string
Type of the Model.
ModelVersion string
The version of the model
Precision float64
Precision of the trained model
ProjectId string
The OCID of the project to associate with the model.
Recall float64
Recall of the trained model
State string
The current state of the Model.
SystemTags map[string]string
Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
TestImageCount int
Total number of testing Images
TestingDatasets []GetModelTestingDataset
The base entity for a Dataset, which is the input for Model creation.
TimeCreated string
The time the Model was created. An RFC3339 formatted datetime string
TimeUpdated string
The time the Model was updated. An RFC3339 formatted datetime string
TotalImageCount int
Total number of training Images
TrainedDurationInHours float64
Total hours actually used for training
TrainingDatasets []GetModelTrainingDataset
The base entity for a Dataset, which is the input for Model creation.
ValidationDatasets []GetModelValidationDataset
The base entity for a Dataset, which is the input for Model creation.
averagePrecision Double
Average precision of the trained model
compartmentId String
Compartment Identifier
confidenceThreshold Double
Confidence ratio of the calculation
definedTags Map<String,String>
Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
description String
A short description of the model.
displayName String
Model Identifier, can be renamed
freeformTags Map<String,String>
Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
id String
Unique identifier that is immutable on creation
isQuickMode Boolean
If It's true, Training is set for recommended epochs needed for quick training.
lifecycleDetails String
A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in Failed state.
maxTrainingDurationInHours Double
The maximum duration in hours for which the training will run.
metrics String
Complete Training Metrics for successful trained model
modelId String
modelType String
Type of the Model.
modelVersion String
The version of the model
precision Double
Precision of the trained model
projectId String
The OCID of the project to associate with the model.
recall Double
Recall of the trained model
state String
The current state of the Model.
systemTags Map<String,String>
Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
testImageCount Integer
Total number of testing Images
testingDatasets List<GetModelTestingDataset>
The base entity for a Dataset, which is the input for Model creation.
timeCreated String
The time the Model was created. An RFC3339 formatted datetime string
timeUpdated String
The time the Model was updated. An RFC3339 formatted datetime string
totalImageCount Integer
Total number of training Images
trainedDurationInHours Double
Total hours actually used for training
trainingDatasets List<GetModelTrainingDataset>
The base entity for a Dataset, which is the input for Model creation.
validationDatasets List<GetModelValidationDataset>
The base entity for a Dataset, which is the input for Model creation.
averagePrecision number
Average precision of the trained model
compartmentId string
Compartment Identifier
confidenceThreshold number
Confidence ratio of the calculation
definedTags {[key: string]: string}
Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
description string
A short description of the model.
displayName string
Model Identifier, can be renamed
freeformTags {[key: string]: string}
Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
id string
Unique identifier that is immutable on creation
isQuickMode boolean
If It's true, Training is set for recommended epochs needed for quick training.
lifecycleDetails string
A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in Failed state.
maxTrainingDurationInHours number
The maximum duration in hours for which the training will run.
metrics string
Complete Training Metrics for successful trained model
modelId string
modelType string
Type of the Model.
modelVersion string
The version of the model
precision number
Precision of the trained model
projectId string
The OCID of the project to associate with the model.
recall number
Recall of the trained model
state string
The current state of the Model.
systemTags {[key: string]: string}
Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
testImageCount number
Total number of testing Images
testingDatasets GetModelTestingDataset[]
The base entity for a Dataset, which is the input for Model creation.
timeCreated string
The time the Model was created. An RFC3339 formatted datetime string
timeUpdated string
The time the Model was updated. An RFC3339 formatted datetime string
totalImageCount number
Total number of training Images
trainedDurationInHours number
Total hours actually used for training
trainingDatasets GetModelTrainingDataset[]
The base entity for a Dataset, which is the input for Model creation.
validationDatasets GetModelValidationDataset[]
The base entity for a Dataset, which is the input for Model creation.
average_precision float
Average precision of the trained model
compartment_id str
Compartment Identifier
confidence_threshold float
Confidence ratio of the calculation
defined_tags Mapping[str, str]
Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
description str
A short description of the model.
display_name str
Model Identifier, can be renamed
freeform_tags Mapping[str, str]
Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
id str
Unique identifier that is immutable on creation
is_quick_mode bool
If It's true, Training is set for recommended epochs needed for quick training.
lifecycle_details str
A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in Failed state.
max_training_duration_in_hours float
The maximum duration in hours for which the training will run.
metrics str
Complete Training Metrics for successful trained model
model_id str
model_type str
Type of the Model.
model_version str
The version of the model
precision float
Precision of the trained model
project_id str
The OCID of the project to associate with the model.
recall float
Recall of the trained model
state str
The current state of the Model.
system_tags Mapping[str, str]
Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
test_image_count int
Total number of testing Images
testing_datasets Sequence[aivision.GetModelTestingDataset]
The base entity for a Dataset, which is the input for Model creation.
time_created str
The time the Model was created. An RFC3339 formatted datetime string
time_updated str
The time the Model was updated. An RFC3339 formatted datetime string
total_image_count int
Total number of training Images
trained_duration_in_hours float
Total hours actually used for training
training_datasets Sequence[aivision.GetModelTrainingDataset]
The base entity for a Dataset, which is the input for Model creation.
validation_datasets Sequence[aivision.GetModelValidationDataset]
The base entity for a Dataset, which is the input for Model creation.
averagePrecision Number
Average precision of the trained model
compartmentId String
Compartment Identifier
confidenceThreshold Number
Confidence ratio of the calculation
definedTags Map<String>
Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: {"foo-namespace.bar-key": "value"}
description String
A short description of the model.
displayName String
Model Identifier, can be renamed
freeformTags Map<String>
Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: {"bar-key": "value"}
id String
Unique identifier that is immutable on creation
isQuickMode Boolean
If It's true, Training is set for recommended epochs needed for quick training.
lifecycleDetails String
A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in Failed state.
maxTrainingDurationInHours Number
The maximum duration in hours for which the training will run.
metrics String
Complete Training Metrics for successful trained model
modelId String
modelType String
Type of the Model.
modelVersion String
The version of the model
precision Number
Precision of the trained model
projectId String
The OCID of the project to associate with the model.
recall Number
Recall of the trained model
state String
The current state of the Model.
systemTags Map<String>
Usage of system tag keys. These predefined keys are scoped to namespaces. Example: {"orcl-cloud.free-tier-retained": "true"}
testImageCount Number
Total number of testing Images
testingDatasets List<Property Map>
The base entity for a Dataset, which is the input for Model creation.
timeCreated String
The time the Model was created. An RFC3339 formatted datetime string
timeUpdated String
The time the Model was updated. An RFC3339 formatted datetime string
totalImageCount Number
Total number of training Images
trainedDurationInHours Number
Total hours actually used for training
trainingDatasets List<Property Map>
The base entity for a Dataset, which is the input for Model creation.
validationDatasets List<Property Map>
The base entity for a Dataset, which is the input for Model creation.

Supporting Types

GetModelTestingDataset

Bucket This property is required. string
The name of the ObjectStorage bucket that contains the input data file.
DatasetId This property is required. string
The OCID of the Data Science Labeling Dataset.
DatasetType This property is required. string
Type of the Dataset.
NamespaceName This property is required. string
The namespace name of the ObjectStorage bucket that contains the input data file.
Object This property is required. string
The object name of the input data file.
Bucket This property is required. string
The name of the ObjectStorage bucket that contains the input data file.
DatasetId This property is required. string
The OCID of the Data Science Labeling Dataset.
DatasetType This property is required. string
Type of the Dataset.
NamespaceName This property is required. string
The namespace name of the ObjectStorage bucket that contains the input data file.
Object This property is required. string
The object name of the input data file.
bucket This property is required. String
The name of the ObjectStorage bucket that contains the input data file.
datasetId This property is required. String
The OCID of the Data Science Labeling Dataset.
datasetType This property is required. String
Type of the Dataset.
namespaceName This property is required. String
The namespace name of the ObjectStorage bucket that contains the input data file.
object This property is required. String
The object name of the input data file.
bucket This property is required. string
The name of the ObjectStorage bucket that contains the input data file.
datasetId This property is required. string
The OCID of the Data Science Labeling Dataset.
datasetType This property is required. string
Type of the Dataset.
namespaceName This property is required. string
The namespace name of the ObjectStorage bucket that contains the input data file.
object This property is required. string
The object name of the input data file.
bucket This property is required. str
The name of the ObjectStorage bucket that contains the input data file.
dataset_id This property is required. str
The OCID of the Data Science Labeling Dataset.
dataset_type This property is required. str
Type of the Dataset.
namespace_name This property is required. str
The namespace name of the ObjectStorage bucket that contains the input data file.
object This property is required. str
The object name of the input data file.
bucket This property is required. String
The name of the ObjectStorage bucket that contains the input data file.
datasetId This property is required. String
The OCID of the Data Science Labeling Dataset.
datasetType This property is required. String
Type of the Dataset.
namespaceName This property is required. String
The namespace name of the ObjectStorage bucket that contains the input data file.
object This property is required. String
The object name of the input data file.

GetModelTrainingDataset

Bucket This property is required. string
The name of the ObjectStorage bucket that contains the input data file.
DatasetId This property is required. string
The OCID of the Data Science Labeling Dataset.
DatasetType This property is required. string
Type of the Dataset.
NamespaceName This property is required. string
The namespace name of the ObjectStorage bucket that contains the input data file.
Object This property is required. string
The object name of the input data file.
Bucket This property is required. string
The name of the ObjectStorage bucket that contains the input data file.
DatasetId This property is required. string
The OCID of the Data Science Labeling Dataset.
DatasetType This property is required. string
Type of the Dataset.
NamespaceName This property is required. string
The namespace name of the ObjectStorage bucket that contains the input data file.
Object This property is required. string
The object name of the input data file.
bucket This property is required. String
The name of the ObjectStorage bucket that contains the input data file.
datasetId This property is required. String
The OCID of the Data Science Labeling Dataset.
datasetType This property is required. String
Type of the Dataset.
namespaceName This property is required. String
The namespace name of the ObjectStorage bucket that contains the input data file.
object This property is required. String
The object name of the input data file.
bucket This property is required. string
The name of the ObjectStorage bucket that contains the input data file.
datasetId This property is required. string
The OCID of the Data Science Labeling Dataset.
datasetType This property is required. string
Type of the Dataset.
namespaceName This property is required. string
The namespace name of the ObjectStorage bucket that contains the input data file.
object This property is required. string
The object name of the input data file.
bucket This property is required. str
The name of the ObjectStorage bucket that contains the input data file.
dataset_id This property is required. str
The OCID of the Data Science Labeling Dataset.
dataset_type This property is required. str
Type of the Dataset.
namespace_name This property is required. str
The namespace name of the ObjectStorage bucket that contains the input data file.
object This property is required. str
The object name of the input data file.
bucket This property is required. String
The name of the ObjectStorage bucket that contains the input data file.
datasetId This property is required. String
The OCID of the Data Science Labeling Dataset.
datasetType This property is required. String
Type of the Dataset.
namespaceName This property is required. String
The namespace name of the ObjectStorage bucket that contains the input data file.
object This property is required. String
The object name of the input data file.

GetModelValidationDataset

Bucket This property is required. string
The name of the ObjectStorage bucket that contains the input data file.
DatasetId This property is required. string
The OCID of the Data Science Labeling Dataset.
DatasetType This property is required. string
Type of the Dataset.
NamespaceName This property is required. string
The namespace name of the ObjectStorage bucket that contains the input data file.
Object This property is required. string
The object name of the input data file.
Bucket This property is required. string
The name of the ObjectStorage bucket that contains the input data file.
DatasetId This property is required. string
The OCID of the Data Science Labeling Dataset.
DatasetType This property is required. string
Type of the Dataset.
NamespaceName This property is required. string
The namespace name of the ObjectStorage bucket that contains the input data file.
Object This property is required. string
The object name of the input data file.
bucket This property is required. String
The name of the ObjectStorage bucket that contains the input data file.
datasetId This property is required. String
The OCID of the Data Science Labeling Dataset.
datasetType This property is required. String
Type of the Dataset.
namespaceName This property is required. String
The namespace name of the ObjectStorage bucket that contains the input data file.
object This property is required. String
The object name of the input data file.
bucket This property is required. string
The name of the ObjectStorage bucket that contains the input data file.
datasetId This property is required. string
The OCID of the Data Science Labeling Dataset.
datasetType This property is required. string
Type of the Dataset.
namespaceName This property is required. string
The namespace name of the ObjectStorage bucket that contains the input data file.
object This property is required. string
The object name of the input data file.
bucket This property is required. str
The name of the ObjectStorage bucket that contains the input data file.
dataset_id This property is required. str
The OCID of the Data Science Labeling Dataset.
dataset_type This property is required. str
Type of the Dataset.
namespace_name This property is required. str
The namespace name of the ObjectStorage bucket that contains the input data file.
object This property is required. str
The object name of the input data file.
bucket This property is required. String
The name of the ObjectStorage bucket that contains the input data file.
datasetId This property is required. String
The OCID of the Data Science Labeling Dataset.
datasetType This property is required. String
Type of the Dataset.
namespaceName This property is required. String
The namespace name of the ObjectStorage bucket that contains the input data file.
object This property is required. String
The object name of the input data file.

Package Details

Repository
oci pulumi/pulumi-oci
License
Apache-2.0
Notes
This Pulumi package is based on the oci Terraform Provider.
Oracle Cloud Infrastructure v2.28.0 published on Thursday, Mar 27, 2025 by Pulumi