Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ads/ads_version.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"version": "2.6.6"
"version": "2.6.7"
}
5 changes: 5 additions & 0 deletions ads/automl/provider.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
runtime_dependency,
OptionalDependency,
)
from ads.common.decorator.deprecate import deprecated
from ads.dataset.label_encoder import DataFrameLabelEncoder
from ads.dataset.helper import is_text_data

Expand Down Expand Up @@ -305,6 +306,10 @@ def decide_estimator(self, **kwargs):

# An installation of oracle labs automl is required only for this class
class OracleAutoMLProvider(AutoMLProvider, ABC):
@deprecated(
"2.6.7",
details="Oracle AutoML is recommended to be directly instantiated by importing automlx package",
)
def __init__(
self, n_jobs=-1, loglevel=None, logger_override=None, model_n_jobs: int = 1
):
Expand Down
4 changes: 2 additions & 2 deletions ads/common/data_serializer.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,9 @@ def __init__(
pass
else:
raise TypeError(
"The provided data type is not json serializable. "
"The supported data types are Dict, str, list, "
"numpy.ndarray, pd.core.series.Series, "
"pd.core.frame.DataFrame. Please "
"pd.core.frame.DataFrame, bytes. Please "
"convert to the supported data types first. "
)

Expand Down Expand Up @@ -106,6 +105,7 @@ def send(self, endpoint: str, dry_run: bool = False, **kwargs):
)
request_kwargs = {"json": self.to_dict()}
request_kwargs["headers"] = headers

if dry_run:
request_kwargs["headers"]["Accept"] = "*/*"
req = requests.Request("POST", endpoint, **request_kwargs).prepare()
Expand Down
1 change: 1 addition & 0 deletions ads/common/model_metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@ class MetadataCustomKeys(str, metaclass=ExtendedEnumMeta):
VALIDATION_DATASET_NUMBER_OF_ROWS = "ValidationDatasetNumberOfRows"
VALIDATION_DATASET_NUMBER_OF_COLS = "ValidationDataSetNumberOfCols"
CLIENT_LIBRARY = "ClientLibrary"
MODEL_FILE_NAME = "ModelFileName"


class MetadataCustomCategory(str, metaclass=ExtendedEnumMeta):
Expand Down
30 changes: 23 additions & 7 deletions ads/common/model_metadata_mixin.py
Original file line number Diff line number Diff line change
Expand Up @@ -173,14 +173,30 @@ def _populate_metadata_custom(self):
category=MetadataCustomCategory.TRAINING_ENV,
)
)
model_metadata_items.append(
ModelCustomMetadataItem(
key=MetadataCustomKeys.MODEL_SERIALIZATION_FORMAT,
value=self.model_file_name.split(".")[-1],
description="The model serialization format.",
category=MetadataCustomCategory.TRAINING_PROFILE,

if self.model_file_name:
model_metadata_items.append(
ModelCustomMetadataItem(
key=MetadataCustomKeys.MODEL_SERIALIZATION_FORMAT,
value=self.model_file_name.split(".")[-1],
description="The model serialization format.",
category=MetadataCustomCategory.TRAINING_PROFILE,
)
)
)
model_metadata_items.append(
ModelCustomMetadataItem(
key=MetadataCustomKeys.MODEL_FILE_NAME,
value=self.model_file_name,
description="The model file name.",
category=MetadataCustomCategory.OTHER,
)
)
else:
logger.warning(
"Unable to extract a model serialization format. "
"The `model_file_name` is not provided."
)

model_metadata_items.append(
ModelCustomMetadataItem(
key=MetadataCustomKeys.CLIENT_LIBRARY,
Expand Down
Loading