Skip to content

Latest commit

 

History

History
86 lines (50 loc) · 1.66 KB

File metadata and controls

86 lines (50 loc) · 1.66 KB
title description keywords author ms.author manager ms.date ms.topic ms.service ms.assetid ROBOTS audience ms.devlang ms.reviewer ms.suite ms.tgt_pltfrm ms.custom
rx_set_compute_context: Sets the compute context (revoscalepy)
Sets the active compute context for revoscalepy computations
context
chuckheinzelman
charlhe
cgronlun
07/15/2019
reference
mlserver
Python

rx_set_compute_context

Usage

revoscalepy.rx_set_compute_context(compute_context: revoscalepy.computecontext.RxComputeContext.RxComputeContext) -> revoscalepy.computecontext.RxComputeContext.RxComputeContext

Description

Sets the active compute context for revoscalepy computations

Arguments

compute_context

Character string specifying class name or description of the specific class to instantiate, or an existing RxComputeContext object. Choices include: “RxLocalSeq” or “local”, “RxInSqlServer”.

Returns

rx_set_compute_context returns the previously active compute context invisibly. rx_get_compute_context returns the active compute context.

See also

RxComputeContext, RxLocalSeq, RxInSqlServer, rx_get_compute_context.

Example

from revoscalepy import RxLocalSeq, RxInSqlServer, rx_get_compute_context, rx_set_compute_context

local_cc = RxLocalSeq()
sql_server_cc = RxInSqlServer('Driver=SQL Server;Server=.;Database=RevoTestDb;Trusted_Connection=True;')
previous_cc = rx_set_compute_context(sql_server_cc)
rx_get_compute_context()