public object Execute(ExecutorContext context)
        {
            var cmdletContext = context as CmdletContext;
            // create request
            var request = new Amazon.LookoutforVision.Model.CreateModelRequest();

            if (cmdletContext.ClientToken != null)
            {
                request.ClientToken = cmdletContext.ClientToken;
            }

            // populate Description
            var requestDescriptionIsNull = true;

            request.Description = new Amazon.LookoutforVision.Model.ModelDescription();
            System.DateTime?requestDescription_description_CreationTimestamp = null;
            if (cmdletContext.Description_CreationTimestamp != null)
            {
                requestDescription_description_CreationTimestamp = cmdletContext.Description_CreationTimestamp.Value;
            }
            if (requestDescription_description_CreationTimestamp != null)
            {
                request.Description.CreationTimestamp = requestDescription_description_CreationTimestamp.Value;
                requestDescriptionIsNull = false;
            }
            System.String requestDescription_description_Description = null;
            if (cmdletContext.Description_Description != null)
            {
                requestDescription_description_Description = cmdletContext.Description_Description;
            }
            if (requestDescription_description_Description != null)
            {
                request.Description.Description = requestDescription_description_Description;
                requestDescriptionIsNull        = false;
            }
            System.DateTime?requestDescription_description_EvaluationEndTimestamp = null;
            if (cmdletContext.Description_EvaluationEndTimestamp != null)
            {
                requestDescription_description_EvaluationEndTimestamp = cmdletContext.Description_EvaluationEndTimestamp.Value;
            }
            if (requestDescription_description_EvaluationEndTimestamp != null)
            {
                request.Description.EvaluationEndTimestamp = requestDescription_description_EvaluationEndTimestamp.Value;
                requestDescriptionIsNull = false;
            }
            System.String requestDescription_description_KmsKeyId = null;
            if (cmdletContext.Description_KmsKeyId != null)
            {
                requestDescription_description_KmsKeyId = cmdletContext.Description_KmsKeyId;
            }
            if (requestDescription_description_KmsKeyId != null)
            {
                request.Description.KmsKeyId = requestDescription_description_KmsKeyId;
                requestDescriptionIsNull     = false;
            }
            System.String requestDescription_description_ModelArn = null;
            if (cmdletContext.Description_ModelArn != null)
            {
                requestDescription_description_ModelArn = cmdletContext.Description_ModelArn;
            }
            if (requestDescription_description_ModelArn != null)
            {
                request.Description.ModelArn = requestDescription_description_ModelArn;
                requestDescriptionIsNull     = false;
            }
            System.String requestDescription_description_ModelVersion = null;
            if (cmdletContext.Description_ModelVersion != null)
            {
                requestDescription_description_ModelVersion = cmdletContext.Description_ModelVersion;
            }
            if (requestDescription_description_ModelVersion != null)
            {
                request.Description.ModelVersion = requestDescription_description_ModelVersion;
                requestDescriptionIsNull         = false;
            }
            Amazon.LookoutforVision.ModelStatus requestDescription_description_Status = null;
            if (cmdletContext.Description_Status != null)
            {
                requestDescription_description_Status = cmdletContext.Description_Status;
            }
            if (requestDescription_description_Status != null)
            {
                request.Description.Status = requestDescription_description_Status;
                requestDescriptionIsNull   = false;
            }
            System.String requestDescription_description_StatusMessage = null;
            if (cmdletContext.Description_StatusMessage != null)
            {
                requestDescription_description_StatusMessage = cmdletContext.Description_StatusMessage;
            }
            if (requestDescription_description_StatusMessage != null)
            {
                request.Description.StatusMessage = requestDescription_description_StatusMessage;
                requestDescriptionIsNull          = false;
            }
            Amazon.LookoutforVision.Model.OutputConfig requestDescription_description_OutputConfig = null;

            // populate OutputConfig
            var requestDescription_description_OutputConfigIsNull = true;

            requestDescription_description_OutputConfig = new Amazon.LookoutforVision.Model.OutputConfig();
            Amazon.LookoutforVision.Model.S3Location requestDescription_description_OutputConfig_description_OutputConfig_S3Location = null;

            // populate S3Location
            var requestDescription_description_OutputConfig_description_OutputConfig_S3LocationIsNull = true;

            requestDescription_description_OutputConfig_description_OutputConfig_S3Location = new Amazon.LookoutforVision.Model.S3Location();
            System.String requestDescription_description_OutputConfig_description_OutputConfig_S3Location_s3Location_Bucket = null;
            if (cmdletContext.S3Location_Bucket != null)
            {
                requestDescription_description_OutputConfig_description_OutputConfig_S3Location_s3Location_Bucket = cmdletContext.S3Location_Bucket;
            }
            if (requestDescription_description_OutputConfig_description_OutputConfig_S3Location_s3Location_Bucket != null)
            {
                requestDescription_description_OutputConfig_description_OutputConfig_S3Location.Bucket = requestDescription_description_OutputConfig_description_OutputConfig_S3Location_s3Location_Bucket;
                requestDescription_description_OutputConfig_description_OutputConfig_S3LocationIsNull  = false;
            }
            System.String requestDescription_description_OutputConfig_description_OutputConfig_S3Location_s3Location_Prefix = null;
            if (cmdletContext.S3Location_Prefix != null)
            {
                requestDescription_description_OutputConfig_description_OutputConfig_S3Location_s3Location_Prefix = cmdletContext.S3Location_Prefix;
            }
            if (requestDescription_description_OutputConfig_description_OutputConfig_S3Location_s3Location_Prefix != null)
            {
                requestDescription_description_OutputConfig_description_OutputConfig_S3Location.Prefix = requestDescription_description_OutputConfig_description_OutputConfig_S3Location_s3Location_Prefix;
                requestDescription_description_OutputConfig_description_OutputConfig_S3LocationIsNull  = false;
            }
            // determine if requestDescription_description_OutputConfig_description_OutputConfig_S3Location should be set to null
            if (requestDescription_description_OutputConfig_description_OutputConfig_S3LocationIsNull)
            {
                requestDescription_description_OutputConfig_description_OutputConfig_S3Location = null;
            }
            if (requestDescription_description_OutputConfig_description_OutputConfig_S3Location != null)
            {
                requestDescription_description_OutputConfig.S3Location = requestDescription_description_OutputConfig_description_OutputConfig_S3Location;
                requestDescription_description_OutputConfigIsNull      = false;
            }
            // determine if requestDescription_description_OutputConfig should be set to null
            if (requestDescription_description_OutputConfigIsNull)
            {
                requestDescription_description_OutputConfig = null;
            }
            if (requestDescription_description_OutputConfig != null)
            {
                request.Description.OutputConfig = requestDescription_description_OutputConfig;
                requestDescriptionIsNull         = false;
            }
            Amazon.LookoutforVision.Model.OutputS3Object requestDescription_description_EvaluationManifest = null;

            // populate EvaluationManifest
            var requestDescription_description_EvaluationManifestIsNull = true;

            requestDescription_description_EvaluationManifest = new Amazon.LookoutforVision.Model.OutputS3Object();
            System.String requestDescription_description_EvaluationManifest_evaluationManifest_Bucket = null;
            if (cmdletContext.EvaluationManifest_Bucket != null)
            {
                requestDescription_description_EvaluationManifest_evaluationManifest_Bucket = cmdletContext.EvaluationManifest_Bucket;
            }
            if (requestDescription_description_EvaluationManifest_evaluationManifest_Bucket != null)
            {
                requestDescription_description_EvaluationManifest.Bucket = requestDescription_description_EvaluationManifest_evaluationManifest_Bucket;
                requestDescription_description_EvaluationManifestIsNull  = false;
            }
            System.String requestDescription_description_EvaluationManifest_evaluationManifest_Key = null;
            if (cmdletContext.EvaluationManifest_Key != null)
            {
                requestDescription_description_EvaluationManifest_evaluationManifest_Key = cmdletContext.EvaluationManifest_Key;
            }
            if (requestDescription_description_EvaluationManifest_evaluationManifest_Key != null)
            {
                requestDescription_description_EvaluationManifest.Key   = requestDescription_description_EvaluationManifest_evaluationManifest_Key;
                requestDescription_description_EvaluationManifestIsNull = false;
            }
            // determine if requestDescription_description_EvaluationManifest should be set to null
            if (requestDescription_description_EvaluationManifestIsNull)
            {
                requestDescription_description_EvaluationManifest = null;
            }
            if (requestDescription_description_EvaluationManifest != null)
            {
                request.Description.EvaluationManifest = requestDescription_description_EvaluationManifest;
                requestDescriptionIsNull = false;
            }
            Amazon.LookoutforVision.Model.OutputS3Object requestDescription_description_EvaluationResult = null;

            // populate EvaluationResult
            var requestDescription_description_EvaluationResultIsNull = true;

            requestDescription_description_EvaluationResult = new Amazon.LookoutforVision.Model.OutputS3Object();
            System.String requestDescription_description_EvaluationResult_evaluationResult_Bucket = null;
            if (cmdletContext.EvaluationResult_Bucket != null)
            {
                requestDescription_description_EvaluationResult_evaluationResult_Bucket = cmdletContext.EvaluationResult_Bucket;
            }
            if (requestDescription_description_EvaluationResult_evaluationResult_Bucket != null)
            {
                requestDescription_description_EvaluationResult.Bucket = requestDescription_description_EvaluationResult_evaluationResult_Bucket;
                requestDescription_description_EvaluationResultIsNull  = false;
            }
            System.String requestDescription_description_EvaluationResult_evaluationResult_Key = null;
            if (cmdletContext.EvaluationResult_Key != null)
            {
                requestDescription_description_EvaluationResult_evaluationResult_Key = cmdletContext.EvaluationResult_Key;
            }
            if (requestDescription_description_EvaluationResult_evaluationResult_Key != null)
            {
                requestDescription_description_EvaluationResult.Key   = requestDescription_description_EvaluationResult_evaluationResult_Key;
                requestDescription_description_EvaluationResultIsNull = false;
            }
            // determine if requestDescription_description_EvaluationResult should be set to null
            if (requestDescription_description_EvaluationResultIsNull)
            {
                requestDescription_description_EvaluationResult = null;
            }
            if (requestDescription_description_EvaluationResult != null)
            {
                request.Description.EvaluationResult = requestDescription_description_EvaluationResult;
                requestDescriptionIsNull             = false;
            }
            Amazon.LookoutforVision.Model.ModelPerformance requestDescription_description_Performance = null;

            // populate Performance
            var requestDescription_description_PerformanceIsNull = true;

            requestDescription_description_Performance = new Amazon.LookoutforVision.Model.ModelPerformance();
            System.Single?requestDescription_description_Performance_performance_F1Score = null;
            if (cmdletContext.Performance_F1Score != null)
            {
                requestDescription_description_Performance_performance_F1Score = cmdletContext.Performance_F1Score.Value;
            }
            if (requestDescription_description_Performance_performance_F1Score != null)
            {
                requestDescription_description_Performance.F1Score = requestDescription_description_Performance_performance_F1Score.Value;
                requestDescription_description_PerformanceIsNull   = false;
            }
            System.Single?requestDescription_description_Performance_performance_Precision = null;
            if (cmdletContext.Performance_Precision != null)
            {
                requestDescription_description_Performance_performance_Precision = cmdletContext.Performance_Precision.Value;
            }
            if (requestDescription_description_Performance_performance_Precision != null)
            {
                requestDescription_description_Performance.Precision = requestDescription_description_Performance_performance_Precision.Value;
                requestDescription_description_PerformanceIsNull     = false;
            }
            System.Single?requestDescription_description_Performance_performance_Recall = null;
            if (cmdletContext.Performance_Recall != null)
            {
                requestDescription_description_Performance_performance_Recall = cmdletContext.Performance_Recall.Value;
            }
            if (requestDescription_description_Performance_performance_Recall != null)
            {
                requestDescription_description_Performance.Recall = requestDescription_description_Performance_performance_Recall.Value;
                requestDescription_description_PerformanceIsNull  = false;
            }
            // determine if requestDescription_description_Performance should be set to null
            if (requestDescription_description_PerformanceIsNull)
            {
                requestDescription_description_Performance = null;
            }
            if (requestDescription_description_Performance != null)
            {
                request.Description.Performance = requestDescription_description_Performance;
                requestDescriptionIsNull        = false;
            }
            // determine if request.Description should be set to null
            if (requestDescriptionIsNull)
            {
                request.Description = null;
            }
            if (cmdletContext.KmsKeyId != null)
            {
                request.KmsKeyId = cmdletContext.KmsKeyId;
            }

            // populate OutputConfig
            var requestOutputConfigIsNull = true;

            request.OutputConfig = new Amazon.LookoutforVision.Model.OutputConfig();
            Amazon.LookoutforVision.Model.S3Location requestOutputConfig_outputConfig_S3Location = null;

            // populate S3Location
            var requestOutputConfig_outputConfig_S3LocationIsNull = true;

            requestOutputConfig_outputConfig_S3Location = new Amazon.LookoutforVision.Model.S3Location();
            System.String requestOutputConfig_outputConfig_S3Location_output_S3Location_Bucket = null;
            if (cmdletContext.Output_S3Location_Bucket != null)
            {
                requestOutputConfig_outputConfig_S3Location_output_S3Location_Bucket = cmdletContext.Output_S3Location_Bucket;
            }
            if (requestOutputConfig_outputConfig_S3Location_output_S3Location_Bucket != null)
            {
                requestOutputConfig_outputConfig_S3Location.Bucket = requestOutputConfig_outputConfig_S3Location_output_S3Location_Bucket;
                requestOutputConfig_outputConfig_S3LocationIsNull  = false;
            }
            System.String requestOutputConfig_outputConfig_S3Location_output_S3Location_Prefix = null;
            if (cmdletContext.Output_S3Location_Prefix != null)
            {
                requestOutputConfig_outputConfig_S3Location_output_S3Location_Prefix = cmdletContext.Output_S3Location_Prefix;
            }
            if (requestOutputConfig_outputConfig_S3Location_output_S3Location_Prefix != null)
            {
                requestOutputConfig_outputConfig_S3Location.Prefix = requestOutputConfig_outputConfig_S3Location_output_S3Location_Prefix;
                requestOutputConfig_outputConfig_S3LocationIsNull  = false;
            }
            // determine if requestOutputConfig_outputConfig_S3Location should be set to null
            if (requestOutputConfig_outputConfig_S3LocationIsNull)
            {
                requestOutputConfig_outputConfig_S3Location = null;
            }
            if (requestOutputConfig_outputConfig_S3Location != null)
            {
                request.OutputConfig.S3Location = requestOutputConfig_outputConfig_S3Location;
                requestOutputConfigIsNull       = false;
            }
            // determine if request.OutputConfig should be set to null
            if (requestOutputConfigIsNull)
            {
                request.OutputConfig = null;
            }
            if (cmdletContext.ProjectName != null)
            {
                request.ProjectName = cmdletContext.ProjectName;
            }

            CmdletOutput output;

            // issue call
            var client = Client ?? CreateClient(_CurrentCredentials, _RegionEndpoint);

            try
            {
                var    response       = CallAWSServiceOperation(client, request);
                object pipelineOutput = null;
                pipelineOutput = cmdletContext.Select(response, this);
                output         = new CmdletOutput
                {
                    PipelineOutput  = pipelineOutput,
                    ServiceResponse = response
                };
            }
            catch (Exception e)
            {
                output = new CmdletOutput {
                    ErrorResponse = e
                };
            }

            return(output);
        }
Exemple #2
0
        public object Execute(ExecutorContext context)
        {
            var cmdletContext = context as CmdletContext;
            // create request
            var request = new Amazon.LookoutforVision.Model.CreateModelRequest();

            if (cmdletContext.ClientToken != null)
            {
                request.ClientToken = cmdletContext.ClientToken;
            }
            if (cmdletContext.Description != null)
            {
                request.Description = cmdletContext.Description;
            }
            if (cmdletContext.KmsKeyId != null)
            {
                request.KmsKeyId = cmdletContext.KmsKeyId;
            }

            // populate OutputConfig
            var requestOutputConfigIsNull = true;

            request.OutputConfig = new Amazon.LookoutforVision.Model.OutputConfig();
            Amazon.LookoutforVision.Model.S3Location requestOutputConfig_outputConfig_S3Location = null;

            // populate S3Location
            var requestOutputConfig_outputConfig_S3LocationIsNull = true;

            requestOutputConfig_outputConfig_S3Location = new Amazon.LookoutforVision.Model.S3Location();
            System.String requestOutputConfig_outputConfig_S3Location_output_S3Location_Bucket = null;
            if (cmdletContext.Output_S3Location_Bucket != null)
            {
                requestOutputConfig_outputConfig_S3Location_output_S3Location_Bucket = cmdletContext.Output_S3Location_Bucket;
            }
            if (requestOutputConfig_outputConfig_S3Location_output_S3Location_Bucket != null)
            {
                requestOutputConfig_outputConfig_S3Location.Bucket = requestOutputConfig_outputConfig_S3Location_output_S3Location_Bucket;
                requestOutputConfig_outputConfig_S3LocationIsNull  = false;
            }
            System.String requestOutputConfig_outputConfig_S3Location_output_S3Location_Prefix = null;
            if (cmdletContext.Output_S3Location_Prefix != null)
            {
                requestOutputConfig_outputConfig_S3Location_output_S3Location_Prefix = cmdletContext.Output_S3Location_Prefix;
            }
            if (requestOutputConfig_outputConfig_S3Location_output_S3Location_Prefix != null)
            {
                requestOutputConfig_outputConfig_S3Location.Prefix = requestOutputConfig_outputConfig_S3Location_output_S3Location_Prefix;
                requestOutputConfig_outputConfig_S3LocationIsNull  = false;
            }
            // determine if requestOutputConfig_outputConfig_S3Location should be set to null
            if (requestOutputConfig_outputConfig_S3LocationIsNull)
            {
                requestOutputConfig_outputConfig_S3Location = null;
            }
            if (requestOutputConfig_outputConfig_S3Location != null)
            {
                request.OutputConfig.S3Location = requestOutputConfig_outputConfig_S3Location;
                requestOutputConfigIsNull       = false;
            }
            // determine if request.OutputConfig should be set to null
            if (requestOutputConfigIsNull)
            {
                request.OutputConfig = null;
            }
            if (cmdletContext.ProjectName != null)
            {
                request.ProjectName = cmdletContext.ProjectName;
            }
            if (cmdletContext.Tag != null)
            {
                request.Tags = cmdletContext.Tag;
            }

            CmdletOutput output;

            // issue call
            var client = Client ?? CreateClient(_CurrentCredentials, _RegionEndpoint);

            try
            {
                var    response       = CallAWSServiceOperation(client, request);
                object pipelineOutput = null;
                pipelineOutput = cmdletContext.Select(response, this);
                output         = new CmdletOutput
                {
                    PipelineOutput  = pipelineOutput,
                    ServiceResponse = response
                };
            }
            catch (Exception e)
            {
                output = new CmdletOutput {
                    ErrorResponse = e
                };
            }

            return(output);
        }
Exemple #3
0
        public object Execute(ExecutorContext context)
        {
            var cmdletContext = context as CmdletContext;
            // create request
            var request = new Amazon.LookoutforVision.Model.StartModelPackagingJobRequest();

            if (cmdletContext.ClientToken != null)
            {
                request.ClientToken = cmdletContext.ClientToken;
            }

            // populate Configuration
            var requestConfigurationIsNull = true;

            request.Configuration = new Amazon.LookoutforVision.Model.ModelPackagingConfiguration();
            Amazon.LookoutforVision.Model.GreengrassConfiguration requestConfiguration_configuration_Greengrass = null;

            // populate Greengrass
            var requestConfiguration_configuration_GreengrassIsNull = true;

            requestConfiguration_configuration_Greengrass = new Amazon.LookoutforVision.Model.GreengrassConfiguration();
            System.String requestConfiguration_configuration_Greengrass_greengrass_CompilerOption = null;
            if (cmdletContext.Greengrass_CompilerOption != null)
            {
                requestConfiguration_configuration_Greengrass_greengrass_CompilerOption = cmdletContext.Greengrass_CompilerOption;
            }
            if (requestConfiguration_configuration_Greengrass_greengrass_CompilerOption != null)
            {
                requestConfiguration_configuration_Greengrass.CompilerOptions = requestConfiguration_configuration_Greengrass_greengrass_CompilerOption;
                requestConfiguration_configuration_GreengrassIsNull           = false;
            }
            System.String requestConfiguration_configuration_Greengrass_greengrass_ComponentDescription = null;
            if (cmdletContext.Greengrass_ComponentDescription != null)
            {
                requestConfiguration_configuration_Greengrass_greengrass_ComponentDescription = cmdletContext.Greengrass_ComponentDescription;
            }
            if (requestConfiguration_configuration_Greengrass_greengrass_ComponentDescription != null)
            {
                requestConfiguration_configuration_Greengrass.ComponentDescription = requestConfiguration_configuration_Greengrass_greengrass_ComponentDescription;
                requestConfiguration_configuration_GreengrassIsNull = false;
            }
            System.String requestConfiguration_configuration_Greengrass_greengrass_ComponentName = null;
            if (cmdletContext.Greengrass_ComponentName != null)
            {
                requestConfiguration_configuration_Greengrass_greengrass_ComponentName = cmdletContext.Greengrass_ComponentName;
            }
            if (requestConfiguration_configuration_Greengrass_greengrass_ComponentName != null)
            {
                requestConfiguration_configuration_Greengrass.ComponentName = requestConfiguration_configuration_Greengrass_greengrass_ComponentName;
                requestConfiguration_configuration_GreengrassIsNull         = false;
            }
            System.String requestConfiguration_configuration_Greengrass_greengrass_ComponentVersion = null;
            if (cmdletContext.Greengrass_ComponentVersion != null)
            {
                requestConfiguration_configuration_Greengrass_greengrass_ComponentVersion = cmdletContext.Greengrass_ComponentVersion;
            }
            if (requestConfiguration_configuration_Greengrass_greengrass_ComponentVersion != null)
            {
                requestConfiguration_configuration_Greengrass.ComponentVersion = requestConfiguration_configuration_Greengrass_greengrass_ComponentVersion;
                requestConfiguration_configuration_GreengrassIsNull            = false;
            }
            List <Amazon.LookoutforVision.Model.Tag> requestConfiguration_configuration_Greengrass_greengrass_Tag = null;

            if (cmdletContext.Greengrass_Tag != null)
            {
                requestConfiguration_configuration_Greengrass_greengrass_Tag = cmdletContext.Greengrass_Tag;
            }
            if (requestConfiguration_configuration_Greengrass_greengrass_Tag != null)
            {
                requestConfiguration_configuration_Greengrass.Tags  = requestConfiguration_configuration_Greengrass_greengrass_Tag;
                requestConfiguration_configuration_GreengrassIsNull = false;
            }
            Amazon.LookoutforVision.TargetDevice requestConfiguration_configuration_Greengrass_greengrass_TargetDevice = null;
            if (cmdletContext.Greengrass_TargetDevice != null)
            {
                requestConfiguration_configuration_Greengrass_greengrass_TargetDevice = cmdletContext.Greengrass_TargetDevice;
            }
            if (requestConfiguration_configuration_Greengrass_greengrass_TargetDevice != null)
            {
                requestConfiguration_configuration_Greengrass.TargetDevice = requestConfiguration_configuration_Greengrass_greengrass_TargetDevice;
                requestConfiguration_configuration_GreengrassIsNull        = false;
            }
            Amazon.LookoutforVision.Model.S3Location requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation = null;

            // populate S3OutputLocation
            var requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocationIsNull = true;

            requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation = new Amazon.LookoutforVision.Model.S3Location();
            System.String requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation_s3OutputLocation_Bucket = null;
            if (cmdletContext.S3OutputLocation_Bucket != null)
            {
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation_s3OutputLocation_Bucket = cmdletContext.S3OutputLocation_Bucket;
            }
            if (requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation_s3OutputLocation_Bucket != null)
            {
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation.Bucket = requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation_s3OutputLocation_Bucket;
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocationIsNull  = false;
            }
            System.String requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation_s3OutputLocation_Prefix = null;
            if (cmdletContext.S3OutputLocation_Prefix != null)
            {
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation_s3OutputLocation_Prefix = cmdletContext.S3OutputLocation_Prefix;
            }
            if (requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation_s3OutputLocation_Prefix != null)
            {
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation.Prefix = requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation_s3OutputLocation_Prefix;
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocationIsNull  = false;
            }
            // determine if requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation should be set to null
            if (requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocationIsNull)
            {
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation = null;
            }
            if (requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation != null)
            {
                requestConfiguration_configuration_Greengrass.S3OutputLocation = requestConfiguration_configuration_Greengrass_configuration_Greengrass_S3OutputLocation;
                requestConfiguration_configuration_GreengrassIsNull            = false;
            }
            Amazon.LookoutforVision.Model.TargetPlatform requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform = null;

            // populate TargetPlatform
            var requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatformIsNull = true;

            requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform = new Amazon.LookoutforVision.Model.TargetPlatform();
            Amazon.LookoutforVision.TargetPlatformAccelerator requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform_targetPlatform_Accelerator = null;
            if (cmdletContext.TargetPlatform_Accelerator != null)
            {
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform_targetPlatform_Accelerator = cmdletContext.TargetPlatform_Accelerator;
            }
            if (requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform_targetPlatform_Accelerator != null)
            {
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform.Accelerator = requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform_targetPlatform_Accelerator;
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatformIsNull       = false;
            }
            Amazon.LookoutforVision.TargetPlatformArch requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform_targetPlatform_Arch = null;
            if (cmdletContext.TargetPlatform_Arch != null)
            {
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform_targetPlatform_Arch = cmdletContext.TargetPlatform_Arch;
            }
            if (requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform_targetPlatform_Arch != null)
            {
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform.Arch  = requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform_targetPlatform_Arch;
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatformIsNull = false;
            }
            Amazon.LookoutforVision.TargetPlatformOs requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform_targetPlatform_Os = null;
            if (cmdletContext.TargetPlatform_Os != null)
            {
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform_targetPlatform_Os = cmdletContext.TargetPlatform_Os;
            }
            if (requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform_targetPlatform_Os != null)
            {
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform.Os    = requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform_targetPlatform_Os;
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatformIsNull = false;
            }
            // determine if requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform should be set to null
            if (requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatformIsNull)
            {
                requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform = null;
            }
            if (requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform != null)
            {
                requestConfiguration_configuration_Greengrass.TargetPlatform = requestConfiguration_configuration_Greengrass_configuration_Greengrass_TargetPlatform;
                requestConfiguration_configuration_GreengrassIsNull          = false;
            }
            // determine if requestConfiguration_configuration_Greengrass should be set to null
            if (requestConfiguration_configuration_GreengrassIsNull)
            {
                requestConfiguration_configuration_Greengrass = null;
            }
            if (requestConfiguration_configuration_Greengrass != null)
            {
                request.Configuration.Greengrass = requestConfiguration_configuration_Greengrass;
                requestConfigurationIsNull       = false;
            }
            // determine if request.Configuration should be set to null
            if (requestConfigurationIsNull)
            {
                request.Configuration = null;
            }
            if (cmdletContext.Description != null)
            {
                request.Description = cmdletContext.Description;
            }
            if (cmdletContext.JobName != null)
            {
                request.JobName = cmdletContext.JobName;
            }
            if (cmdletContext.ModelVersion != null)
            {
                request.ModelVersion = cmdletContext.ModelVersion;
            }
            if (cmdletContext.ProjectName != null)
            {
                request.ProjectName = cmdletContext.ProjectName;
            }

            CmdletOutput output;

            // issue call
            var client = Client ?? CreateClient(_CurrentCredentials, _RegionEndpoint);

            try
            {
                var    response       = CallAWSServiceOperation(client, request);
                object pipelineOutput = null;
                pipelineOutput = cmdletContext.Select(response, this);
                output         = new CmdletOutput
                {
                    PipelineOutput  = pipelineOutput,
                    ServiceResponse = response
                };
            }
            catch (Exception e)
            {
                output = new CmdletOutput {
                    ErrorResponse = e
                };
            }

            return(output);
        }