teradataml 20.0.0.1__py3-none-any.whl → 20.0.0.3__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of teradataml might be problematic. Click here for more details.

Files changed (240) hide show
  1. teradataml/LICENSE-3RD-PARTY.pdf +0 -0
  2. teradataml/LICENSE.pdf +0 -0
  3. teradataml/README.md +306 -0
  4. teradataml/__init__.py +10 -3
  5. teradataml/_version.py +1 -1
  6. teradataml/analytics/__init__.py +3 -2
  7. teradataml/analytics/analytic_function_executor.py +299 -16
  8. teradataml/analytics/analytic_query_generator.py +92 -0
  9. teradataml/analytics/byom/__init__.py +3 -2
  10. teradataml/analytics/json_parser/metadata.py +13 -3
  11. teradataml/analytics/json_parser/utils.py +13 -6
  12. teradataml/analytics/meta_class.py +40 -1
  13. teradataml/analytics/sqle/DecisionTreePredict.py +1 -1
  14. teradataml/analytics/sqle/__init__.py +11 -2
  15. teradataml/analytics/table_operator/__init__.py +4 -3
  16. teradataml/analytics/uaf/__init__.py +21 -2
  17. teradataml/analytics/utils.py +66 -1
  18. teradataml/analytics/valib.py +1 -1
  19. teradataml/automl/__init__.py +1502 -323
  20. teradataml/automl/custom_json_utils.py +139 -61
  21. teradataml/automl/data_preparation.py +247 -307
  22. teradataml/automl/data_transformation.py +32 -12
  23. teradataml/automl/feature_engineering.py +325 -86
  24. teradataml/automl/model_evaluation.py +44 -35
  25. teradataml/automl/model_training.py +122 -153
  26. teradataml/catalog/byom.py +8 -8
  27. teradataml/clients/pkce_client.py +1 -1
  28. teradataml/common/__init__.py +2 -1
  29. teradataml/common/constants.py +72 -0
  30. teradataml/common/deprecations.py +13 -7
  31. teradataml/common/garbagecollector.py +152 -120
  32. teradataml/common/messagecodes.py +11 -2
  33. teradataml/common/messages.py +4 -1
  34. teradataml/common/sqlbundle.py +26 -4
  35. teradataml/common/utils.py +225 -14
  36. teradataml/common/wrapper_utils.py +1 -1
  37. teradataml/context/context.py +82 -2
  38. teradataml/data/SQL_Fundamentals.pdf +0 -0
  39. teradataml/data/complaints_test_tokenized.csv +353 -0
  40. teradataml/data/complaints_tokens_model.csv +348 -0
  41. teradataml/data/covid_confirm_sd.csv +83 -0
  42. teradataml/data/dataframe_example.json +27 -1
  43. teradataml/data/docs/sqle/docs_17_20/CFilter.py +132 -0
  44. teradataml/data/docs/sqle/docs_17_20/NaiveBayes.py +162 -0
  45. teradataml/data/docs/sqle/docs_17_20/OutlierFilterFit.py +2 -0
  46. teradataml/data/docs/sqle/docs_17_20/Pivoting.py +279 -0
  47. teradataml/data/docs/sqle/docs_17_20/Shap.py +203 -0
  48. teradataml/data/docs/sqle/docs_17_20/TDNaiveBayesPredict.py +189 -0
  49. teradataml/data/docs/sqle/docs_17_20/TFIDF.py +142 -0
  50. teradataml/data/docs/sqle/docs_17_20/TextParser.py +3 -3
  51. teradataml/data/docs/sqle/docs_17_20/Unpivoting.py +216 -0
  52. teradataml/data/docs/tableoperator/docs_17_20/Image2Matrix.py +118 -0
  53. teradataml/data/docs/uaf/docs_17_20/ACF.py +1 -10
  54. teradataml/data/docs/uaf/docs_17_20/ArimaEstimate.py +1 -1
  55. teradataml/data/docs/uaf/docs_17_20/ArimaForecast.py +35 -5
  56. teradataml/data/docs/uaf/docs_17_20/ArimaValidate.py +3 -1
  57. teradataml/data/docs/uaf/docs_17_20/ArimaXEstimate.py +293 -0
  58. teradataml/data/docs/uaf/docs_17_20/AutoArima.py +354 -0
  59. teradataml/data/docs/uaf/docs_17_20/BreuschGodfrey.py +3 -2
  60. teradataml/data/docs/uaf/docs_17_20/BreuschPaganGodfrey.py +1 -1
  61. teradataml/data/docs/uaf/docs_17_20/Convolve.py +13 -10
  62. teradataml/data/docs/uaf/docs_17_20/Convolve2.py +4 -1
  63. teradataml/data/docs/uaf/docs_17_20/CopyArt.py +145 -0
  64. teradataml/data/docs/uaf/docs_17_20/CumulPeriodogram.py +5 -4
  65. teradataml/data/docs/uaf/docs_17_20/DFFT2Conv.py +4 -4
  66. teradataml/data/docs/uaf/docs_17_20/DWT.py +235 -0
  67. teradataml/data/docs/uaf/docs_17_20/DWT2D.py +214 -0
  68. teradataml/data/docs/uaf/docs_17_20/DickeyFuller.py +18 -21
  69. teradataml/data/docs/uaf/docs_17_20/DurbinWatson.py +1 -1
  70. teradataml/data/docs/uaf/docs_17_20/ExtractResults.py +1 -1
  71. teradataml/data/docs/uaf/docs_17_20/FilterFactory1d.py +160 -0
  72. teradataml/data/docs/uaf/docs_17_20/GenseriesSinusoids.py +1 -1
  73. teradataml/data/docs/uaf/docs_17_20/GoldfeldQuandt.py +9 -31
  74. teradataml/data/docs/uaf/docs_17_20/HoltWintersForecaster.py +4 -2
  75. teradataml/data/docs/uaf/docs_17_20/IDFFT2.py +1 -8
  76. teradataml/data/docs/uaf/docs_17_20/IDWT.py +236 -0
  77. teradataml/data/docs/uaf/docs_17_20/IDWT2D.py +226 -0
  78. teradataml/data/docs/uaf/docs_17_20/IQR.py +134 -0
  79. teradataml/data/docs/uaf/docs_17_20/LineSpec.py +1 -1
  80. teradataml/data/docs/uaf/docs_17_20/LinearRegr.py +2 -2
  81. teradataml/data/docs/uaf/docs_17_20/MAMean.py +3 -3
  82. teradataml/data/docs/uaf/docs_17_20/Matrix2Image.py +297 -0
  83. teradataml/data/docs/uaf/docs_17_20/MatrixMultiply.py +15 -6
  84. teradataml/data/docs/uaf/docs_17_20/PACF.py +0 -1
  85. teradataml/data/docs/uaf/docs_17_20/Portman.py +2 -2
  86. teradataml/data/docs/uaf/docs_17_20/PowerSpec.py +2 -2
  87. teradataml/data/docs/uaf/docs_17_20/Resample.py +9 -1
  88. teradataml/data/docs/uaf/docs_17_20/SAX.py +246 -0
  89. teradataml/data/docs/uaf/docs_17_20/SeasonalNormalize.py +17 -10
  90. teradataml/data/docs/uaf/docs_17_20/SignifPeriodicities.py +1 -1
  91. teradataml/data/docs/uaf/docs_17_20/WhitesGeneral.py +3 -1
  92. teradataml/data/docs/uaf/docs_17_20/WindowDFFT.py +368 -0
  93. teradataml/data/dwt2d_dataTable.csv +65 -0
  94. teradataml/data/dwt_dataTable.csv +8 -0
  95. teradataml/data/dwt_filterTable.csv +3 -0
  96. teradataml/data/finance_data4.csv +13 -0
  97. teradataml/data/grocery_transaction.csv +19 -0
  98. teradataml/data/idwt2d_dataTable.csv +5 -0
  99. teradataml/data/idwt_dataTable.csv +8 -0
  100. teradataml/data/idwt_filterTable.csv +3 -0
  101. teradataml/data/interval_data.csv +5 -0
  102. teradataml/data/jsons/paired_functions.json +14 -0
  103. teradataml/data/jsons/sqle/17.20/TD_CFilter.json +118 -0
  104. teradataml/data/jsons/sqle/17.20/TD_NaiveBayes.json +193 -0
  105. teradataml/data/jsons/sqle/17.20/TD_NaiveBayesPredict.json +212 -0
  106. teradataml/data/jsons/sqle/17.20/TD_OneClassSVM.json +9 -9
  107. teradataml/data/jsons/sqle/17.20/TD_Pivoting.json +280 -0
  108. teradataml/data/jsons/sqle/17.20/TD_Shap.json +222 -0
  109. teradataml/data/jsons/sqle/17.20/TD_TFIDF.json +162 -0
  110. teradataml/data/jsons/sqle/17.20/TD_TextParser.json +1 -1
  111. teradataml/data/jsons/sqle/17.20/TD_Unpivoting.json +235 -0
  112. teradataml/data/jsons/sqle/20.00/TD_KMeans.json +250 -0
  113. teradataml/data/jsons/sqle/20.00/TD_SMOTE.json +266 -0
  114. teradataml/data/jsons/sqle/20.00/TD_VectorDistance.json +278 -0
  115. teradataml/data/jsons/storedprocedure/17.20/TD_COPYART.json +71 -0
  116. teradataml/data/jsons/storedprocedure/17.20/TD_FILTERFACTORY1D.json +150 -0
  117. teradataml/data/jsons/tableoperator/17.20/IMAGE2MATRIX.json +53 -0
  118. teradataml/data/jsons/uaf/17.20/TD_ACF.json +1 -18
  119. teradataml/data/jsons/uaf/17.20/TD_ARIMAESTIMATE.json +3 -16
  120. teradataml/data/jsons/uaf/17.20/TD_ARIMAFORECAST.json +0 -3
  121. teradataml/data/jsons/uaf/17.20/TD_ARIMAVALIDATE.json +5 -3
  122. teradataml/data/jsons/uaf/17.20/TD_ARIMAXESTIMATE.json +362 -0
  123. teradataml/data/jsons/uaf/17.20/TD_AUTOARIMA.json +469 -0
  124. teradataml/data/jsons/uaf/17.20/TD_BINARYMATRIXOP.json +0 -3
  125. teradataml/data/jsons/uaf/17.20/TD_BINARYSERIESOP.json +0 -2
  126. teradataml/data/jsons/uaf/17.20/TD_BREUSCH_GODFREY.json +2 -1
  127. teradataml/data/jsons/uaf/17.20/TD_BREUSCH_PAGAN_GODFREY.json +2 -5
  128. teradataml/data/jsons/uaf/17.20/TD_CONVOLVE.json +3 -6
  129. teradataml/data/jsons/uaf/17.20/TD_CONVOLVE2.json +1 -3
  130. teradataml/data/jsons/uaf/17.20/TD_CUMUL_PERIODOGRAM.json +0 -5
  131. teradataml/data/jsons/uaf/17.20/TD_DFFT.json +1 -4
  132. teradataml/data/jsons/uaf/17.20/TD_DFFT2.json +2 -7
  133. teradataml/data/jsons/uaf/17.20/TD_DFFT2CONV.json +1 -2
  134. teradataml/data/jsons/uaf/17.20/TD_DFFTCONV.json +0 -2
  135. teradataml/data/jsons/uaf/17.20/TD_DICKEY_FULLER.json +10 -19
  136. teradataml/data/jsons/uaf/17.20/TD_DTW.json +3 -6
  137. teradataml/data/jsons/uaf/17.20/TD_DWT.json +173 -0
  138. teradataml/data/jsons/uaf/17.20/TD_DWT2D.json +160 -0
  139. teradataml/data/jsons/uaf/17.20/TD_FITMETRICS.json +1 -1
  140. teradataml/data/jsons/uaf/17.20/TD_GOLDFELD_QUANDT.json +16 -30
  141. teradataml/data/jsons/uaf/17.20/{TD_HOLT_WINTERS_FORECAST.json → TD_HOLT_WINTERS_FORECASTER.json} +1 -2
  142. teradataml/data/jsons/uaf/17.20/TD_IDFFT2.json +1 -15
  143. teradataml/data/jsons/uaf/17.20/TD_IDWT.json +162 -0
  144. teradataml/data/jsons/uaf/17.20/TD_IDWT2D.json +149 -0
  145. teradataml/data/jsons/uaf/17.20/TD_IQR.json +117 -0
  146. teradataml/data/jsons/uaf/17.20/TD_LINEAR_REGR.json +1 -1
  147. teradataml/data/jsons/uaf/17.20/TD_LINESPEC.json +1 -1
  148. teradataml/data/jsons/uaf/17.20/TD_MAMEAN.json +1 -3
  149. teradataml/data/jsons/uaf/17.20/TD_MATRIX2IMAGE.json +209 -0
  150. teradataml/data/jsons/uaf/17.20/TD_PACF.json +2 -2
  151. teradataml/data/jsons/uaf/17.20/TD_POWERSPEC.json +5 -5
  152. teradataml/data/jsons/uaf/17.20/TD_RESAMPLE.json +48 -28
  153. teradataml/data/jsons/uaf/17.20/TD_SAX.json +210 -0
  154. teradataml/data/jsons/uaf/17.20/TD_SEASONALNORMALIZE.json +12 -6
  155. teradataml/data/jsons/uaf/17.20/TD_SIMPLEEXP.json +0 -1
  156. teradataml/data/jsons/uaf/17.20/TD_TRACKINGOP.json +8 -8
  157. teradataml/data/jsons/uaf/17.20/TD_UNDIFF.json +1 -1
  158. teradataml/data/jsons/uaf/17.20/TD_UNNORMALIZE.json +1 -1
  159. teradataml/data/jsons/uaf/17.20/TD_WINDOWDFFT.json +410 -0
  160. teradataml/data/load_example_data.py +8 -2
  161. teradataml/data/medical_readings.csv +101 -0
  162. teradataml/data/naivebayestextclassifier_example.json +1 -1
  163. teradataml/data/naivebayestextclassifierpredict_example.json +11 -0
  164. teradataml/data/patient_profile.csv +101 -0
  165. teradataml/data/peppers.png +0 -0
  166. teradataml/data/real_values.csv +14 -0
  167. teradataml/data/sax_example.json +8 -0
  168. teradataml/data/scripts/deploy_script.py +1 -1
  169. teradataml/data/scripts/lightgbm/dataset.template +157 -0
  170. teradataml/data/scripts/lightgbm/lightgbm_class_functions.template +247 -0
  171. teradataml/data/scripts/lightgbm/lightgbm_function.template +216 -0
  172. teradataml/data/scripts/lightgbm/lightgbm_sklearn.template +159 -0
  173. teradataml/data/scripts/sklearn/sklearn_fit.py +194 -160
  174. teradataml/data/scripts/sklearn/sklearn_fit_predict.py +136 -115
  175. teradataml/data/scripts/sklearn/sklearn_function.template +34 -16
  176. teradataml/data/scripts/sklearn/sklearn_model_selection_split.py +155 -137
  177. teradataml/data/scripts/sklearn/sklearn_neighbors.py +1 -1
  178. teradataml/data/scripts/sklearn/sklearn_score.py +12 -3
  179. teradataml/data/scripts/sklearn/sklearn_transform.py +162 -24
  180. teradataml/data/star_pivot.csv +8 -0
  181. teradataml/data/target_udt_data.csv +8 -0
  182. teradataml/data/templates/open_source_ml.json +3 -1
  183. teradataml/data/teradataml_example.json +20 -1
  184. teradataml/data/timestamp_data.csv +4 -0
  185. teradataml/data/titanic_dataset_unpivoted.csv +19 -0
  186. teradataml/data/uaf_example.json +55 -1
  187. teradataml/data/unpivot_example.json +15 -0
  188. teradataml/data/url_data.csv +9 -0
  189. teradataml/data/vectordistance_example.json +4 -0
  190. teradataml/data/windowdfft.csv +16 -0
  191. teradataml/dataframe/copy_to.py +1 -1
  192. teradataml/dataframe/data_transfer.py +5 -3
  193. teradataml/dataframe/dataframe.py +1002 -201
  194. teradataml/dataframe/fastload.py +3 -3
  195. teradataml/dataframe/functions.py +867 -0
  196. teradataml/dataframe/row.py +160 -0
  197. teradataml/dataframe/setop.py +2 -2
  198. teradataml/dataframe/sql.py +840 -33
  199. teradataml/dataframe/window.py +1 -1
  200. teradataml/dbutils/dbutils.py +878 -34
  201. teradataml/dbutils/filemgr.py +48 -1
  202. teradataml/geospatial/geodataframe.py +1 -1
  203. teradataml/geospatial/geodataframecolumn.py +1 -1
  204. teradataml/hyperparameter_tuner/optimizer.py +13 -13
  205. teradataml/lib/aed_0_1.dll +0 -0
  206. teradataml/opensource/__init__.py +1 -1
  207. teradataml/opensource/{sklearn/_class.py → _class.py} +102 -17
  208. teradataml/opensource/_lightgbm.py +950 -0
  209. teradataml/opensource/{sklearn/_wrapper_utils.py → _wrapper_utils.py} +1 -2
  210. teradataml/opensource/{sklearn/constants.py → constants.py} +13 -10
  211. teradataml/opensource/sklearn/__init__.py +0 -1
  212. teradataml/opensource/sklearn/_sklearn_wrapper.py +1019 -574
  213. teradataml/options/__init__.py +9 -23
  214. teradataml/options/configure.py +42 -4
  215. teradataml/options/display.py +2 -2
  216. teradataml/plot/axis.py +4 -4
  217. teradataml/scriptmgmt/UserEnv.py +13 -9
  218. teradataml/scriptmgmt/lls_utils.py +77 -23
  219. teradataml/store/__init__.py +13 -0
  220. teradataml/store/feature_store/__init__.py +0 -0
  221. teradataml/store/feature_store/constants.py +291 -0
  222. teradataml/store/feature_store/feature_store.py +2223 -0
  223. teradataml/store/feature_store/models.py +1505 -0
  224. teradataml/store/vector_store/__init__.py +1586 -0
  225. teradataml/table_operators/Script.py +2 -2
  226. teradataml/table_operators/TableOperator.py +106 -20
  227. teradataml/table_operators/query_generator.py +3 -0
  228. teradataml/table_operators/table_operator_query_generator.py +3 -1
  229. teradataml/table_operators/table_operator_util.py +102 -56
  230. teradataml/table_operators/templates/dataframe_register.template +69 -0
  231. teradataml/table_operators/templates/dataframe_udf.template +63 -0
  232. teradataml/telemetry_utils/__init__.py +0 -0
  233. teradataml/telemetry_utils/queryband.py +52 -0
  234. teradataml/utils/dtypes.py +4 -2
  235. teradataml/utils/validators.py +34 -2
  236. {teradataml-20.0.0.1.dist-info → teradataml-20.0.0.3.dist-info}/METADATA +311 -3
  237. {teradataml-20.0.0.1.dist-info → teradataml-20.0.0.3.dist-info}/RECORD +240 -157
  238. {teradataml-20.0.0.1.dist-info → teradataml-20.0.0.3.dist-info}/WHEEL +0 -0
  239. {teradataml-20.0.0.1.dist-info → teradataml-20.0.0.3.dist-info}/top_level.txt +0 -0
  240. {teradataml-20.0.0.1.dist-info → teradataml-20.0.0.3.dist-info}/zip-safe +0 -0
@@ -4,24 +4,31 @@ def SeasonalNormalize(data=None, data_filter_expr=None, season_cycle=None,
4
4
  **generic_arguments):
5
5
  """
6
6
  DESCRIPTION:
7
- The function SeasonalNormalize() takes a non-stationary series and
8
- normalizes the series by removing the unit roots. The function can
9
- be used with any cyclic data that can be subdivided into a collection
10
- of logical periods, in which each period can be further subdivided
11
- into a collection of logical intervals.
7
+ SeasonalNormalize() takes a non-stationary series and normalizes the
8
+ series by first dividing the series into cycles and intervals, then averaging
9
+ and normalizing with respect to each interval over all cycles.
10
+ This form of normalization is effective relative to eliminating
11
+ non-stationary properties such as unit roots and periodicities.
12
12
 
13
13
  The following procedure is an example of how to use SeasonalNormalize():
14
14
  1. Detect the unit roots using DickeyFuller().
15
- 2. Use DIFF() or SeasonalNormalize() to eliminate unit roots.
16
- 3. Use Unnormalize() to undo the effects of SeasonalNormalize(),
17
- and compare it to the original series.
15
+ 2. Use SeasonalNormalize() to create a series with potentially the unit roots eliminated.
16
+ 3. Use DickeyFuller() to verify that unit roots were eliminated from the newly-formed normalized series.
17
+ 4. Use ArimaEstimate() and ArimaValidate() to create an ARIMA model from the normalized series.
18
+ 5. Use ArimaForecast() to forecast the normalized series.
19
+ 6. Use Unnormalize() passing in the forecasted series and the original unnormalized series to
20
+ produce a forecasted series with the effects of SeasonalNormalize() removed.
18
21
 
19
22
 
20
23
  PARAMETERS:
21
24
  data:
22
25
  Required Argument.
23
- Specifies a logical-runtime series, with real number
24
- elements.
26
+ Single input source that contains univariate series instances.
27
+ The associated "payload_content" is 'REAL'.
28
+ The payload is the series element magnitude.
29
+ TDSeries must include the usage of the "interval" parameter
30
+ that is the interval to used by the function to divide the
31
+ series cycles into intervals.
25
32
  Types: TDSeries
26
33
 
27
34
  data_filter_expr:
@@ -16,7 +16,7 @@ def SignifPeriodicities(data=None, data_filter_expr=None,
16
16
  SignifPeriodicities():
17
17
  1. Use ArimaEstimate() to identify spectral candidates.
18
18
  2. Use ArimaValidate() to validate spectral candidates.
19
- 3. Use Plot() to plot the results.
19
+ 3. Use DataFrame.plot() to plot the results.
20
20
  4. Compute the test statistic.
21
21
  5. Use SignifPeriodicities() on the periodicities of interest.
22
22
  More than one periodicities can be entered using the
@@ -161,7 +161,9 @@ def WhitesGeneral(data=None, data_filter_expr=None, variables_count=None,
161
161
  payload_field=["ACTUAL_VALUE","CALC_VALUE","RESIDUAL"],
162
162
  payload_content="MULTIVAR_REAL")
163
163
 
164
- uaf_out1 = WhitesGeneral(data=data_series_df, variables_count=3, significance_level=0.05)
164
+ uaf_out1 = WhitesGeneral(data=data_series_df,
165
+ variables_count=3,
166
+ significance_level=0.05)
165
167
 
166
168
  # Print the result DataFrame.
167
169
  print(uaf_out1.result)
@@ -0,0 +1,368 @@
1
+ def WindowDFFT(data=None, data_filter_expr=None, dfft_algorithm=None,
2
+ dfft_zero_padding_ok=True, dfft_freq_style="K_INTEGRAL",
3
+ dfft_hertz_sample_rate=None, dfft_human_readable=True,
4
+ window_size_num=None, window_size_perc=None,
5
+ window_overlap=0, window_is_symmetric=True,
6
+ window_scale=None, window_type=None,
7
+ window_exponential_center=None,
8
+ window_exponential_tau=None, window_gaussian_std=None,
9
+ window_general_cosine_coeff=None,
10
+ window_general_gaussian_shape=None,
11
+ window_general_gaussian_sigma=None,
12
+ window_general_hamming_alpha=None,
13
+ window_kaiser_beta=None, window_taylor_num_sidelobes=4,
14
+ window_taylor_sidelobe_suppression=30,
15
+ window_taylor_norm=True, window_tukey_alpha=None,
16
+ output_fmt_content=None, **generic_arguments):
17
+ """
18
+ DESCRIPTION:
19
+ WindowDFFT() function applies a user-selected window to data before
20
+ processing it with DFFT(). Windows are used to remove
21
+ noise or spectral leakage. The window type is determined
22
+ for the specific use case based on signal frequency,
23
+ amplitude, strength and so on.
24
+
25
+
26
+ PARAMETERS:
27
+ data:
28
+ Required Argument.
29
+ Specifies the time series or spatial series.
30
+ Types: TDSeries, TDAnalyticResult
31
+
32
+ data_filter_expr:
33
+ Optional Argument.
34
+ Specifies the filter expression for "data".
35
+ Types: ColumnExpression
36
+
37
+ dfft_algorithm:
38
+ Optional Argument.
39
+ Specifies the user-defined algorithm that bypasses the
40
+ internal DFFT planner, and influences the core DFFT
41
+ algorithm associated with the primary DFFT calculation.
42
+ Note:
43
+ * When "dfft_algorithm" is not passed, then the internal DFFT planner selects
44
+ the most efficient algorithm for the operation.
45
+ Permitted Values: COOLEY_TUKEY, SINGLETON
46
+ Types: str
47
+
48
+ dfft_zero_padding_ok:
49
+ Optional Argument.
50
+ Specifies whether to add zeros to the end of a given
51
+ series to achieve a more efficient computation for the
52
+ Fast Fourier Transform coefficients.
53
+ Default Value: True
54
+ Types: bool
55
+
56
+ dfft_freq_style:
57
+ Optional Argument.
58
+ Specifies the format or values associated with the x-axis of the
59
+ output.
60
+ Permitted Values:
61
+ * K_INTEGRAL: Integer representation.
62
+ * K_SAMPLE_RATE: Integer normalized to number entries, with ranges from -0.5 to +0.5.
63
+ * K_RADIANS: Radian ranges from -π to +π.
64
+ * K_HERTZ: Frequency in hertz. Must be used in conjunction with "dfft_hertz_sample_rate".
65
+ Default Value: K_INTEGRAL
66
+ Types: str
67
+
68
+ dfft_hertz_sample_rate:
69
+ Optional Argument.
70
+ Specifies the sample rate as a floating point constant, in
71
+ hertz. A value of 10000.0 indicates that the sample
72
+ points were obtained by sampling at a rate of 10,000
73
+ hertz.
74
+ Note:
75
+ * "dfft_hertz_sample_rate" is only valid with "dfft_freq_style".
76
+ Types: float
77
+
78
+ dfft_human_readable:
79
+ Optional Argument.
80
+ Specifies whether the produced output rows are in human-readable or raw form.
81
+ Human-readable output is symmetric around 0, such as -3, -2, -1, 0, 1, 2, 3 whereas
82
+ raw output is sequential, starting at zero, such as 0, 1, 2, 3.
83
+ Permitted Values:
84
+ * True: Human-readable output.
85
+ * False: Raw output.
86
+ Default Value: True
87
+ Types: bool
88
+
89
+ window_size_num:
90
+ Optional Argument.
91
+ Specifies the size of the window.
92
+ Note:
93
+ * "window_size_num" must be greater than zero.
94
+ * "window_size_num" and "window_size_perc" are mutually exclusive.
95
+ Types: int
96
+
97
+ window_size_perc:
98
+ Optional Argument.
99
+ Specifies the size of the window within a series as a percentage.
100
+ Note:
101
+ * "window_size_perc" must be greater than zero.
102
+ * "window_size_num" and "window_size_perc" are mutually exclusive.
103
+ Types: float
104
+
105
+ window_overlap:
106
+ Optional Argument.
107
+ Specifies the number of values by which the window slides down for
108
+ each DFFT calculation within a series.
109
+ Note:
110
+ * The value must be less than the window size.
111
+ * To use fraction form, use "window_size_perc".
112
+ Default Value: 0
113
+ Types: int
114
+
115
+ window_is_symmetric:
116
+ Optional Argument.
117
+ Specifies whether to use a symmetric or periodic window.
118
+ Permitted Values:
119
+ * False: Periodic
120
+ * True: Symmetric
121
+ Default Value: True
122
+ Types: bool
123
+
124
+ window_scale:
125
+ Optional Argument.
126
+ Specifies the spectral density type applied to the result values.
127
+ Permitted Values: DENSITY, SPECTRUM
128
+ Types: str
129
+
130
+ window_type:
131
+ Optional Argument.
132
+ Specifies the type of window to use.
133
+ Note:
134
+ * Some windows have additional options such as Taylor, in which case refer
135
+ to the Taylor parameter for specific Taylor window options.
136
+ Permitted Values:
137
+ * BARTHANN
138
+ * BARTLETT,
139
+ * BLACKMAN,
140
+ * BLACKMANHARRIS,
141
+ * BOHMAN,
142
+ * BOXCAR,
143
+ * COSINE,
144
+ * EXPONENTIAL,
145
+ * FLATTOP,
146
+ * GAUSSIAN,
147
+ * GENERAL_COSINE,
148
+ * GENERAL_GAUSSIAN,
149
+ * GENERAL_HAMMING,
150
+ * HAMMING, HANN,
151
+ * KAISER,
152
+ * NUTTALL,
153
+ * PARZEN,
154
+ * TAYLOR,
155
+ * TRIANG,
156
+ * TUKEY
157
+ Types: str
158
+
159
+ window_exponential_center:
160
+ Optional Argument.
161
+ Specifies the center of the window.
162
+ It is a parameter for "window_type" as EXPONENTIAL.
163
+ The default value is (windowSize - 1 ) / 2.
164
+ Types: float
165
+
166
+ window_exponential_tau:
167
+ Optional Argument.
168
+ Specifies the amount of window decay.
169
+ It is a parameter for window_type as EXPONENTIAL.
170
+ If the "window_exponential_center" is zero, then use ( windowSize - 1 ) / ln( x ) if x is the
171
+ fractional part of the window remaining at the end of
172
+ the window.
173
+ Types: float
174
+
175
+ window_gaussian_std:
176
+ Optional Argument. Required if "window_type" is GAUSSIAN.
177
+ Specifies the standard deviation of the Gaussian window.
178
+ Types: float
179
+
180
+ window_general_cosine_coeff:
181
+ Optional Argument. Required if "window_type" is GENERAL_GUASSIAN.
182
+ Specifies the list of weighing coefficients.
183
+ Types: float, list of float
184
+
185
+ window_general_gaussian_shape:
186
+ Optional Argument. Required if "window_type" is GENERAL_GUASSIAN.
187
+ specifies the gaussian shape.
188
+ Types: float
189
+
190
+ window_general_gaussian_sigma:
191
+ Optional Argument. Required if "window_type" is GENERAL_GUASSIAN.
192
+ Specifies the standard deviation value.
193
+ Types: float
194
+
195
+ window_general_hamming_alpha:
196
+ Optional Argument. Required if "window_type" is GENERAL_HAMMING.
197
+ Specifies the value of the window coefficient.
198
+ Types: float
199
+
200
+ window_kaiser_beta:
201
+ Optional Argument. Required if "window_type" is KAISER.
202
+ Specifies the shape between the main lobe width and side
203
+ lobe level.
204
+ Types: float
205
+
206
+ window_taylor_num_sidelobes:
207
+ Optional Argument.
208
+ Specifies the number of nearly constant level sidelobes
209
+ adjacent to the main lobe.
210
+ Default Value: 4
211
+ Types: int
212
+
213
+ window_taylor_sidelobe_suppression:
214
+ Optional Argument.
215
+ Specifies the suppression level of the side lobe in decibels
216
+ relative to the DC gain of the main lobe.
217
+ Default Value: 30
218
+ Types: float
219
+
220
+ window_taylor_norm:
221
+ Optional Argument.
222
+ Specifies the normalization factor for the Taylor window.
223
+ Permitted Values:
224
+ * False: For an even sized window, divides the window by the
225
+ value that would occur between the two middle values.
226
+ * True : For an odd sized window, divides the window by the
227
+ largest (middle) value.
228
+ Default Value: True
229
+ Types: bool
230
+
231
+ window_tukey_alpha:
232
+ Optional Argument. Required if "window_type" is TUKEY.
233
+ Specifies the shape of the window inside the cosine-tapered region.
234
+ A value of 0 is a rectangular window and value of 1 is the same as a Hann window.
235
+ Types: float
236
+
237
+ output_fmt_content:
238
+ Optional Argument.
239
+ Specifies how the Fourier coefficients should be output.
240
+ Permitted Values:
241
+ * COMPLEX
242
+ * AMPL_PHASE_RADIANS
243
+ * AMPL_PHASE_DEGREES
244
+ * AMPL_PHASE
245
+ * MULTIVAR_COMPLEX
246
+ * MULTIVAR_AMPL_PHASE_RADIANS
247
+ * MULTIVAR_AMPL_PHASE_DEGREES
248
+ * MULTIVAR_AMPL_PHASE
249
+ Types: str
250
+
251
+ **generic_arguments:
252
+ Specifies the generic keyword arguments of UAF functions.
253
+ Below are the generic keyword arguments:
254
+ persist:
255
+ Optional Argument.
256
+ Specifies whether to persist the results of the
257
+ function in a table or not. When set to True,
258
+ results are persisted in a table; otherwise,
259
+ results are garbage collected at the end of the
260
+ session.
261
+ Note that, when UAF function is executed, an
262
+ analytic result table (ART) is created.
263
+ Default Value: False
264
+ Types: bool
265
+
266
+ volatile:
267
+ Optional Argument.
268
+ Specifies whether to put the results of the
269
+ function in a volatile ART or not. When set to
270
+ True, results are stored in a volatile ART,
271
+ otherwise not.
272
+ Default Value: False
273
+ Types: bool
274
+
275
+ output_table_name:
276
+ Optional Argument.
277
+ Specifies the name of the table to store results.
278
+ If not specified, a unique table name is internally
279
+ generated.
280
+ Types: str
281
+
282
+ output_db_name:
283
+ Optional Argument.
284
+ Specifies the name of the database to create output
285
+ table into. If not specified, table is created into
286
+ database specified by the user at the time of context
287
+ creation or configuration parameter. Argument is ignored,
288
+ if "output_table_name" is not specified.
289
+ Types: str
290
+
291
+
292
+ RETURNS:
293
+ Instance of WindowDFFT.
294
+ Output teradataml DataFrames can be accessed using attribute
295
+ references, such as WindowDFFT_obj.<attribute_name>.
296
+ Output teradataml DataFrame attribute name is:
297
+ 1. result
298
+
299
+
300
+ RAISES:
301
+ TeradataMlException, TypeError, ValueError
302
+
303
+
304
+ EXAMPLES:
305
+ # Notes:
306
+ # 1. Get the connection to Vantage, before importing the
307
+ # function in user space.
308
+ # 2. User can import the function, if it is available on
309
+ # Vantage user is connected to.
310
+ # 3. To check the list of UAF analytic functions available
311
+ # on Vantage user connected to, use
312
+ # "display_analytic_functions()".
313
+
314
+ # Check the list of available UAF analytic functions.
315
+ display_analytic_functions(type="UAF")
316
+
317
+ # Import function WindowDFFT.
318
+ from teradataml import WindowDFFT
319
+
320
+ # Load the example data.
321
+ load_example_data("uaf", ["windowdfft"])
322
+
323
+ # Create teradataml DataFrame object.
324
+ data = DataFrame.from_table("windowdfft")
325
+
326
+ # Create teradataml TDSeries object.
327
+ data_series_df = TDSeries(data=data,
328
+ id="id",
329
+ row_index="row_i",
330
+ row_index_style="SEQUENCE",
331
+ payload_field=["v2"],
332
+ payload_content="REAL")
333
+
334
+ # Example 1: Execute WindowDFFT() function to apply a window to the data before processing it with DFFT()
335
+ # with window_type as BOHMAN and dfft_human_readable is True.
336
+ uaf_out = WindowDFFT(data=data_series_df,
337
+ window_size_num=15,
338
+ window_overlap=2,
339
+ window_type="BOHMAN",
340
+ window_is_symmetric=True,
341
+ window_scale="SPECTRUM",
342
+ dfft_algorithm="SINGLETON",
343
+ dfft_zero_padding_ok=True,
344
+ dfft_freq_style="K_INTEGRAL",
345
+ dfft_human_readable=True)
346
+
347
+ # Print the result DataFrame.
348
+ print(uaf_out.result)
349
+
350
+ # Example 2: Execute WindowDFFT() function to apply a window to the data before processing it with DFFT()
351
+ # with additional window parameters for window_type as GENERAL_COSINE and dfft_human_readable is False.
352
+ uaf_out1 = WindowDFFT(data=data_series_df,
353
+ window_size_num=15,
354
+ window_overlap=2,
355
+ window_type="GENERAL_COSINE",
356
+ window_general_cosine_coeff=[2.3,3.7],
357
+ window_is_symmetric=True,
358
+ window_scale="SPECTRUM",
359
+ dfft_algorithm="SINGLETON",
360
+ dfft_zero_padding_ok=True,
361
+ dfft_freq_style="K_INTEGRAL",
362
+ dfft_human_readable=False)
363
+
364
+ # Print the result DataFrame.
365
+ print(uaf_out1.result)
366
+
367
+ """
368
+
@@ -0,0 +1,65 @@
1
+ id,x,y,v
2
+ 1,6,2,1e+00
3
+ 1,5,4,1e+00
4
+ 1,8,8,1e+00
5
+ 1,8,6,1e+00
6
+ 1,2,6,1e+00
7
+ 1,4,5,1e+00
8
+ 1,5,3,1e+00
9
+ 1,6,8,1e+00
10
+ 1,6,1,1e+00
11
+ 1,3,1,1e+00
12
+ 1,3,5,1e+00
13
+ 1,8,5,1e+00
14
+ 1,1,6,1e+00
15
+ 1,1,3,1e+00
16
+ 1,7,8,1e+00
17
+ 1,5,8,1e+00
18
+ 1,7,7,1e+00
19
+ 1,4,4,1e+00
20
+ 1,8,7,1e+00
21
+ 1,2,1,1e+00
22
+ 1,5,7,1e+00
23
+ 1,5,2,1e+00
24
+ 1,2,2,1e+00
25
+ 1,1,2,1e+00
26
+ 1,7,5,1e+00
27
+ 1,2,5,1e+00
28
+ 1,8,4,1e+00
29
+ 1,6,6,1e+00
30
+ 1,8,2,1e+00
31
+ 1,6,7,1e+00
32
+ 1,4,8,1e+00
33
+ 1,7,2,1e+00
34
+ 1,2,8,1e+00
35
+ 1,7,6,1e+00
36
+ 1,8,3,1e+00
37
+ 1,2,7,1e+00
38
+ 1,1,1,1e+00
39
+ 1,3,4,1e+00
40
+ 1,3,8,1e+00
41
+ 1,6,4,1e+00
42
+ 1,5,5,1e+00
43
+ 1,4,3,1e+00
44
+ 1,5,1,1e+00
45
+ 1,4,6,1e+00
46
+ 1,4,1,1e+00
47
+ 1,8,1,1e+00
48
+ 1,1,5,1e+00
49
+ 1,7,1,1e+00
50
+ 1,1,4,1e+00
51
+ 1,1,8,1e+00
52
+ 1,7,4,1e+00
53
+ 1,1,7,1e+00
54
+ 1,3,2,1e+00
55
+ 1,4,2,1e+00
56
+ 1,4,7,1e+00
57
+ 1,2,3,1e+00
58
+ 1,2,4,1e+00
59
+ 1,3,3,1e+00
60
+ 1,5,6,1e+00
61
+ 1,6,5,1e+00
62
+ 1,7,3,1e+00
63
+ 1,3,7,1e+00
64
+ 1,6,3,1e+00
65
+ 1,3,6,1e+00
@@ -0,0 +1,8 @@
1
+ id,rowi,v
2
+ 1,7,4e+00
3
+ 1,5,-2e+00
4
+ 1,4,1e+00
5
+ 1,2,7e+00
6
+ 1,1,3e+00
7
+ 1,3,1e+00
8
+ 1,6,5e+00
@@ -0,0 +1,3 @@
1
+ id,seq,lo,hi
2
+ 1,1,1.00E+00,1.00E+00
3
+ 1,2,1,-1
@@ -0,0 +1,13 @@
1
+ id,period,expenditure,income,investment
2
+ 3,1,1650.0,1910.0,611.0
3
+ 3,2,1685.0,1943.0,597.0
4
+ 3,3,1722.0,1976.0,603.0
5
+ 3,4,1752.0,2018.0,619.0
6
+ 3,5,2145.0,2521.0,833.0
7
+ 3,6,2164.0,2545.0,860.0
8
+ 3,7,2206.0,2580.0,870.0
9
+ 3,8,2225.0,2620.0,830.0
10
+ 3,9,2235.0,2639.0,801.0
11
+ 3,10,2237.0,2618.0,824.0
12
+ 3,11,2250.0,2628.0,831.0
13
+ 3,12,2271.0,2651.0,830.0
@@ -0,0 +1,19 @@
1
+ tranid,period,storeid,region,item,sku,category
2
+ 999,20100715,1,west,milk,1,dairy
3
+ 1002,20100715,1,west,milk,1,dairy
4
+ 1500,20100715,3,west,butter,2,dairy
5
+ 999,20100715,1,west,butter,2,dairy
6
+ 1002,20100715,1,west,butter,2,dairy
7
+ 1500,20100715,3,west,eggs,3,dairy
8
+ 999,20100715,1,west,eggs,3,dairy
9
+ 1002,20100715,1,west,spinach,3,produce
10
+ 1500,20100715,3,west,flour,4,baking
11
+ 999,19990715,1,west,flour,4,baking
12
+ 1000,20100715,1,west,milk,1,dairy
13
+ 999,19990715,1,west,spinach,4,produce
14
+ 1000,20100715,1,west,eggs,3,dairy
15
+ 1000,19990715,1,west,flour,4,baking
16
+ 1000,19990715,1,west,spinach,2,produce
17
+ 1001,20100715,1,west,milk,1,dairy
18
+ 1001,20100715,1,west,butter,2,dairy
19
+ 1001,20100715,1,west,eggs,3,dairy
@@ -0,0 +1,5 @@
1
+ id,x,y,v
2
+ 1,1,1,1e+00
3
+ 1,3,1,3e+00
4
+ 1,2,1,2e+00
5
+ 1,4,1,4e+00
@@ -0,0 +1,8 @@
1
+ id,rowi,approx,detail
2
+ 1,7,4e+00,-1e+00
3
+ 1,5,-2e+00,1e+00
4
+ 1,4,1e+00,0e+00
5
+ 1,2,7e+00,0e+00
6
+ 1,1,3e+00,1e+00
7
+ 1,3,1e+00,-1e+00
8
+ 1,6,5e+00,0e+00
@@ -0,0 +1,3 @@
1
+ id,seq,lo,hi
2
+ 1,1,7.071067811865476e-01,7.071067811865476e-01
3
+ 1,2,7.071067811865476e-01,-7.071067811865476e-01
@@ -0,0 +1,5 @@
1
+ id,int_col,value_col,value_col1,str_col1,str_col2
2
+ 0,20,"DAY","YEAR","100 04:23:59","04-10"
3
+ 1,240,"HOUR","YEAR","P100DT4H23M59S","P100Y4M"
4
+ 2,657,"MINUTE","MONTH","PT73H","-P14M"
5
+ 3,1234,"SECOND","MONTH","100 04:23:59","06-10"
@@ -83,6 +83,20 @@
83
83
  "reference_function": "_TDEvaluate"
84
84
  }
85
85
  },
86
+ "NaiveBayes": {
87
+ "predict": {
88
+ "reference_function": "TDNaiveBayesPredict",
89
+ "input_arguments": [
90
+ "object"
91
+ ],
92
+ "model_output_arguments": [
93
+ "result"
94
+ ]
95
+ },
96
+ "evaluate": {
97
+ "reference_function": "_TDEvaluate"
98
+ }
99
+ },
86
100
  "NaiveBayesTextClassifierTrainer": {
87
101
  "predict": {
88
102
  "reference_function": "NaiveBayesTextClassifierPredict",