ym_env()

Read(138) Label: start python, ymodel,

Description:

Initialize the environment by setting an environment variable.

Syntax:

ym_env()

ym_env(1)

Note:

You need to first configure certain parameters, such as sAppHome, sLicenseFile and sPythonHome, in userconfig.xml file under YModelCli external library’s directory before environment initialization. For more information, see Section 2.18 in External Libray Guide.

When the function is executed, a store directory with subdirectories under it will be generated. By default:  

[sAppHome]/store/data_md  Contains data files for model building by default

  [sAppHome]/store/data_pd  Contains data files to be scored by default

  [sAppHome]/store/predict  Contains the model file by default

ym_env(1) forces a restart of Python service.

Return value:

An env object

Example:

 

A

 

1

=ym_env()

Initialize the environment to start Python service

2

>ym_close(A1)

Reduce resource usage