关闭

关闭

关闭

封号提示

内容

首页 Matlab2015a并行计算工具箱用户指南

Matlab2015a并行计算工具箱用户指南.pdf

Matlab2015a并行计算工具箱用户指南

MarcoPolochina
2017-09-10 0人阅读 0 0 0 暂无简介 举报

简介:本文档为《Matlab2015a并行计算工具箱用户指南pdf》,可适用于IT/计算机领域

ParallelComputingToolboxtradeUser#sGuideRaHowtoContactMathWorksLatestnews:wwwmathworkscomSalesandservices:wwwmathworkscomsalesandservicesUsercommunity:wwwmathworkscommatlabcentralTechnicalsupport:wwwmathworkscomsupportcontactusPhone:TheMathWorks,IncAppleHillDriveNatick,MAParallelComputingToolboxtradeUser#sGuidecopyCOPYRIGHTndashbyTheMathWorks,IncThesoftwaredescribedinthisdocumentisfurnishedunderalicenseagreementThesoftwaremaybeusedorcopiedonlyunderthetermsofthelicenseagreementNopartofthismanualmaybephotocopiedorreproducedinanyformwithoutpriorwrittenconsentfromTheMathWorks,IncFEDERALACQUISITION:ThisprovisionappliestoallacquisitionsoftheProgramandDocumentationby,for,orthroughthefederalgovernmentoftheUnitedStatesByacceptingdeliveryoftheProgramorDocumentation,thegovernmentherebyagreesthatthissoftwareordocumentationqualifiesascommercialcomputersoftwareorcommercialcomputersoftwaredocumentationassuchtermsareusedordefinedinFAR,DFARSPart,andDFARSAccordingly,thetermsandconditionsofthisAgreementandonlythoserightsspecifiedinthisAgreement,shallpertaintoandgoverntheuse,modification,reproduction,release,performance,display,anddisclosureoftheProgramandDocumentationbythefederalgovernment(orotherentityacquiringfororthroughthefederalgovernment)andshallsupersedeanyconflictingcontractualtermsorconditionsIfthisLicensefailstomeetthegovernment#sneedsorisinconsistentinanyrespectwithfederalprocurementlaw,thegovernmentagreestoreturntheProgramandDocumentation,unused,toTheMathWorks,IncTrademarksMATLABandSimulinkareregisteredtrademarksofTheMathWorks,IncSeewwwmathworkscomtrademarksforalistofadditionaltrademarksOtherproductorbrandnamesmaybetrademarksorregisteredtrademarksoftheirrespectiveholdersPatentsMathWorksproductsareprotectedbyoneormoreUSpatentsPleaseseewwwmathworkscompatentsformoreinformationRevisionHistoryNovemberOnlineonlyNewforVersion(ReleaseSP)MarchOnlineonlyRevisedforVersion(ReleaseSP)SeptemberOnlineonlyRevisedforVersion(ReleaseSP)NovemberOnlineonlyRevisedforVersion(ReleaseSP)MarchOnlineonlyRevisedforVersion(Releasea)SeptemberOnlineonlyRevisedforVersion(Releaseb)MarchOnlineonlyRevisedforVersion(Releasea)SeptemberOnlineonlyRevisedforVersion(Releaseb)MarchOnlineonlyRevisedforVersion(Releasea)OctoberOnlineonlyRevisedforVersion(Releaseb)MarchOnlineonlyRevisedforVersion(Releasea)SeptemberOnlineonlyRevisedforVersion(Releaseb)MarchOnlineonlyRevisedforVersion(Releasea)SeptemberOnlineonlyRevisedforVersion(Releaseb)AprilOnlineonlyRevisedforVersion(Releasea)SeptemberOnlineonlyRevisedforVersion(Releaseb)MarchOnlineonlyRevisedforVersion(Releasea)SeptemberOnlineonlyRevisedforVersion(Releaseb)MarchOnlineonlyRevisedforVersion(Releasea)SeptemberOnlineonlyRevisedforVersion(Releaseb)MarchOnlineonlyRevisedforVersion(Releasea)OctoberOnlineonlyRevisedforVersion(Releaseb)MarchOnlineonlyRevisedforVersion(Releasea)vContentsGettingStartedParallelComputingToolboxProductDescriptionKeyFeaturesParallelComputingwithMathWorksProductsKeyProblemsAddressedbyParallelComputingRunParallelforLoops(parfor)ExecuteBatchJobsinParallelPartitionLargeDataSetsIntroductiontoParallelSolutionsInteractivelyRunaLoopinParallelRunaBatchJobRunaBatchParallelLoopRunScriptasBatchJobfromtheCurrentFolderBrowserDistributeArraysandRunSPMDDetermineProductInstallationandVersionsParallelforLoops(parfor)IntroductiontoparforparforLoopsinMATLABDecidingWhentoUseparforCreateaparforLoopComparingforLoopsandparforLoopsviContentsReductions:CumulativeValuesUpdatedbyEachIterationparforProgrammingConsiderationsMATLABPathErrorHandlingparforLimitationsInputsandOutputsinparforLoopsFunctionswithInteractiveInputsDisplayingOutputObjectsandHandlesinparforLoopsUsingObjectsinparforLoopsHandleClassesSlicedVariablesReferencingFunctionHandlesNestingandFlowinparforLoopsNestedFunctionsNestedLoopsNestedspmdStatementsBreakandReturnStatementsPCodeScriptsVariablesandTransparencyinparforLoopsUnambiguousVariableNamesTransparencyStructureArraysinparforLoopsScalarExpansionwithSlicedOutputsGlobalandPersistentVariablesClassificationofVariablesinparforLoopsNotesaboutRequiredandRecommendedGuidelinesLoopVariableSlicedVariablesCharacteristicsofaSlicedVariableSlicedInputandOutputVariablesBroadcastVariablesviiReductionVariablesBasicRulesforReductionVariablesFurtherConsiderationswithReductionVariablesExample:UsingaCustomReductionFunctionTemporaryVariablesUninitializedTemporariesTemporaryVariablesIntendedasReductionVariablesImprovingparforPerformanceWheretoCreateArraysSlicingArraysOptimizingonLocalvsClusterWorkersParallelPoolsWhatIsaParallelPoolAutomaticallyStartandStopaParallelPoolAlternativeWaystoStartandStopPoolsPoolSizeandClusterSelectionConvertNestedforLoopstoparforSingleProgramMultipleData(spmd)ExecuteSimultaneouslyonMultipleDataSetsIntroductionWhentoUsespmdDefineanspmdStatementDisplayOutputAccessWorkerVariableswithCompositesIntroductiontoCompositesCreateCompositesinspmdStatementsVariablePersistenceandSequencesofspmdCreateCompositesOutsidespmdStatementsDistributeArraysDistributedVersusCodistributedArraysCreateDistributedArraysviiiContentsCreateCodistributedArraysProgrammingTipsMATLABPathErrorHandlingLimitationsInteractiveParallelComputationwithpmodepmodeVersusspmdRunCommunicatingJobsInteractivelyUsingpmodeParallelCommandWindowRunningpmodeInteractiveJobsonaClusterPlottingDistributedDataUsingpmodepmodeLimitationsandUnexpectedResultsUsingGraphicsinpmodepmodeTroubleshootingConnectivityTestingHostnameResolutionSocketConnectionsMathwithCodistributedArraysNondistributedVersusDistributedArraysIntroductionNondistributedArraysCodistributedArraysixWorkingwithCodistributedArraysHowMATLABSoftwareDistributesArraysCreatingaCodistributedArrayLocalArraysObtaininginformationAbouttheArrayChangingtheDimensionofDistributionRestoringtheFullArrayIndexingintoaCodistributedArrayDimensionalDistributionLoopingOveraDistributedRange(fordrange)ParallelizingaforLoopCodistributedArraysinafordrangeLoopMATLABFunctionsonDistributedandCodistributedArraysProgrammingOverviewHowParallelComputingProductsRunaJobOverviewToolboxandServerComponentsLifeCycleofaJobCreateSimpleIndependentJobsProgramaJobonaLocalClusterParallelPreferencesClustersandClusterProfilesClusterProfileManagerDiscoverClustersImportandExportClusterProfilesCreateandModifyClusterProfilesValidateClusterProfilesApplyClusterProfilesinClientCodeApplyCallbackstoMJSJobsandTasksxContentsJobMonitorJobMonitorGUIManageJobsUsingtheJobMonitorIdentifyTaskErrorsUsingtheJobMonitorProgrammingTipsProgramDevelopmentGuidelinesCurrentWorkingDirectoryofaMATLABWorkerWritingtoFilesfromWorkersSavingorSendingObjectsUsingclearfunctionsRunningTasksThatCallSimulinkSoftwareUsingthepauseFunctionTransmittingLargeAmountsofDataInterruptingaJobSpeedingUpaJobControlRandomNumberStreamsDifferentWorkersClientandWorkersClientandGPUWorkerCPUandWorkerGPUProfilingParallelCodeIntroductionCollectingParallelProfileDataViewingParallelProfileDataBenchmarkingPerformanceHPCChallengeBenchmarksTroubleshootingandDebuggingObjectDataSizeLimitationsFileAccessandPermissionsNoResultsorFailedJobConnectionProblemsBetweentheClientandMJSSFTPError:ReceivedMessageTooLongRunmapreduceonaParallelPoolStartParallelPoolCompareParallelmapreducexiRunmapreduceonaHadoopClusterClusterPreparationOutpormatandOrderCalculateMeanDelayPartitionaDatastoreinParallelProgramIndependentJobsProgramIndependentJobsProgramIndependentJobsonaLocalClusterCreateandRunJobswithaLocalClusterLocalClusterBehaviorProgramIndependentJobsforaSupportedSchedulerCreateandRunJobsManageObjectsintheSchedulerShareCodewiththeWorkersWorkersAccessFilesDirectlyPassDatatoandfromWorkerSessionsPassMATLABCodeforStartupandFinishProgramIndependentJobsforaGenericSchedulerOverviewMATLABClientSubmitFunctionExamplemdashWritetheSubmitFunctionMATLABWorkerDecodeFunctionExamplemdashWritetheDecodeFunctionExamplemdashProgramandRunaJobintheClientSuppliedSubmitandDecodeFunctionsManageJobswithGenericSchedulerSummaryxiiContentsProgramCommunicatingJobsProgramCommunicatingJobsProgramCommunicatingJobsforaSupportedSchedulerSchedulersandConditionsCodetheTaskFunctionCodeintheClientProgramCommunicatingJobsforaGenericSchedulerIntroductionCodeintheClientFurtherNotesonCommunicatingJobsNumberofTasksinaCommunicatingJobAvoidDeadlockandOtherDependencyErrorsGPUComputingGPUCapabilitiesandPerformanceCapabilitiesPerformanceBenchmarkingEstablishArraysonaGPUTransferArraysBetweenWorkspaceandGPUCreateGPUArraysDirectlyExaminegpuArrayCharacteristicsRunBuiltInFunctionsonaGPUMATLABFunctionswithgpuArrayArgumentsExample:FunctionswithgpuArrayInputandOutputSparseArraysonaGPUConsiderationsforComplexNumbersRunElementwiseMATLABCodeonGPUMATLABCodevsgpuArrayObjectsRunYourMATLABFunctionsonaGPUxiiiExample:RunYourMATLABCodeSupportedMATLABCodeIdentifyandSelectaGPUDeviceExample:SelectaGPURunCUDAorPTXCodeonGPUOverviewCreateaCUDAKernelObjectRunaCUDAKernelCompleteKernelWorkflowRunMEXFunctionsContainingCUDACodeWriteaMEXFileContainingCUDACodeSetUpforMEXFileCompilationCompileaGPUMEXFileRuntheResultingMEXFunctionsComparisontoaCUDAKernelAccessComplexDataMeasureandImproveGPUPerformanceBasicWorkflowforImprovingPerformanceAdvancedToolsforImprovingPerformanceBestPracticesforImprovingPerformanceMeasurePerformanceontheGPUVectorizeforImprovedGPUPerformancexivContentsObjectsmdashAlphabeticalListFunctionsmdashAlphabeticalListGlossaryGettingStartedbullldquoParallelComputingToolboxProductDescriptionrdquoonpagebullldquoParallelComputingwithMathWorksProductsrdquoonpagebullldquoKeyProblemsAddressedbyParallelComputingrdquoonpagebullldquoIntroductiontoParallelSolutionsrdquoonpagebullldquoDetermineProductInstallationandVersionsrdquoonpageGettingStartedParallelComputingToolboxProductDescriptionPerformparallelcomputationsonmulticorecomputers,GPUs,andcomputerclustersParallelComputingToolboxletsyousolvecomputationallyanddataintensiveproblemsusingmulticoreprocessors,GPUs,andcomputerclustersHighlevelconstructsmdashparallelforloops,specialarraytypes,andparallelizednumericalalgorithmsmdashletyouparallelizeMATLABregapplicationswithoutCUDAorMPIprogrammingYoucanusethetoolboxwithSimulinkregtorunmultiplesimulationsofamodelinparallelThetoolboxletsyouusethefullprocessingpowerofmulticoredesktopsbyexecutingapplicationsonworkers(MATLABcomputationalengines)thatrunlocallyWithoutchangingthecode,youcanrunthesameapplicationsonacomputerclusteroragridcomputingservice(usingMATLABDistributedComputingServertrade)YoucanrunparallelapplicationsinteractivelyorinbatchKeyFeaturesbullParallelforloops(parfor)forrunningtaskparallelalgorithmsonmultipleprocessorsbullSupportforCUDAenabledNVIDIAGPUsbullFulluseofmulticoreprocessorsonthedesktopviaworkersthatrunlocallybullComputerclusterandgridsupport(withMATLABDistributedComputingServer)bullInteractiveandbatchexecutionofparallelapplicationsbullDistributedarraysandspmd(singleprogrammultipledata)forlargedatasethandlinganddataparallelalgorithmsParallelComputingwithMathWorksProductsParallelComputingwithMathWorksProductsInadditiontoParallelComputingToolboxprovidingalocalclusterofworkersforyourclientmachine,MATLABDistributedComputingServersoftwareallowsyoutorunasmanyMATLABworkersonaremoteclusterofcomputersasyourlicensingallowsMostMathWorksproductsletyoucodeinsuchawayastorunapplicationsinparallelForexample,Simulinkmodelscanrunsimultaneouslyinparallel,asdescribedinldquoRunParallelSimulationsrdquoMATLABCompilertradeandMATLABCompilerSDKtradesoftwareletyoubuildanddeployparallelapplications,asshowninSeveralMathWorksproductsnowofferbuiltinsupportfortheparallelcomputingproducts,withoutrequiringextracodingForthecurrentlistoftheseproductsandtheirparallelfunctionality,see:http:wwwmathworkscomproductsparallelcomputingbuiltinparallelsupporthtmlGettingStartedKeyProblemsAddressedbyParallelComputingInthissectionldquoRunParallelforLoops(parfor)rdquoonpageldquoExecuteBatchJobsinParallelrdquoonpageldquoPartitionLargeDataSetsrdquoonpageRunParallelforLoops(parfor)Manyapplicationsinvolvemultiplesegmentsofcode,someofwhicharerepetitiveOftenyoucanuseforloopstosolvethesecasesTheabilitytoexecutecodeinparallel,ononecomputeroronaclusterofcomputers,cansignificantlyimproveperformanceinmanycases:bullParametersweepapplicationsbullManyiterationsmdashAsweepmighttakealongtimebecauseitcomprisesmanyiterationsEachiterationbyitselfmightnottakelongtoexecute,buttocompletethousandsormillionsofiterationsinserialcouldtakealongtimebullLongiterationsmdashAsweepmightnothavealotofiterations,buteachiterationcouldtakealongtimetorunTypically,theonlydifferencebetweeniterationsisdefinedbydifferentinputdataInthesecases,theabilitytorunseparatesweepiterationssimultaneouslycanimproveperformanceEvaluatingsuchiterationsinparallelisanidealwaytosweepthroughlargeormultipledatasetsTheonlyrestrictiononparallelloopsisthatnoiterationsbeallowedtodependonanyotheriterationsbullTestsuiteswithindependentsegmentsmdashForapplicationsthatrunaseriesofunrelatedtasks,youcanrunthesetaskssimultaneouslyonseparateresourcesYoumightnothaveusedaforloopforacasesuchasthiscomprisingdistinctlydifferenttasks,butaparforloopcouldofferanappropriatesolutionParallelComputingToolboxsoftwareimprovestheperformanceofsuchloopexecutionbyallowingseveralMATLABworkerstoexecuteindividualloopiterationssimultaneouslyForexample,aloopofiterationscouldrunonaclusterofMATLABworkers,sothatsimultaneously,theworkerseachexecuteonl

用户评价(0)

关闭

新课改视野下建构高中语文教学实验成果报告(32KB)

抱歉,积分不足下载失败,请稍后再试!

提示

试读已结束,如需要继续阅读或者下载,敬请购买!

评分:

/656

意见
反馈

立即扫码关注

爱问共享资料微信公众号

返回
顶部

举报
资料