Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhance generate_pipeline_code to format code to follow lint standards #4004

Closed
jeremyliweishih opened this issue Feb 15, 2023 · 0 comments · Fixed by #4005
Closed

Enhance generate_pipeline_code to format code to follow lint standards #4004

jeremyliweishih opened this issue Feb 15, 2023 · 0 comments · Fixed by #4005
Assignees

Comments

@jeremyliweishih
Copy link
Contributor

Currently generate_pipeline_code generates a long string for the whole pipeline. It would be easier if this string was formatted to follow our lint standards for readability.

BinaryClassificationPipeline(
  component_graph={
    'Imputer': ['Imputer', 'X', 'y'], 
    'My Drop Null Columns Transformer': [MyDropNullColumns, 'Imputer.x', 'y'], 
    'DateTime Featurizer': ['DateTime Featurizer', 'My Drop Null Columns Transformer.x', 'y'], 
    'Natural Language Featurizer': ['Natural Language Featurizer', 'DateTime Featurizer.x', 'y'], 
    'One Hot Encoder': ['One Hot Encoder', 'Natural Language Featurizer.x', 'y'], 
    'Random Forest Classifier': ['Random Forest Classifier', 'One Hot Encoder.x', 'y']}, 
  parameters={
    'Imputer':{'categorical_impute_strategy': 'most_frequent', 'numeric_impute_strategy': 'mean', 'boolean_impute_strategy': 'most_frequent', 'categorical_fill_value': None, 'numeric_fill_value': None, 'boolean_fill_value': None}, 
    'My Drop Null Columns Transformer':{'pct_null_threshold': 1.0}, 
    'DateTime Featurizer':{'features_to_extract': ['year', 'month', 'day_of_week', 'hour'], 'encode_as_categories': False, 'time_index': None}, 'One Hot Encoder':{'top_n': 10, 'features_to_encode': None, 'categories': None, 'drop': 'if_binary', 'handle_unknown': 'ignore', 'handle_missing': 'error'}, 
    'Random Forest Classifier':{'n_estimators': 100, 'max_depth': 6, 'n_jobs': -1}}, 
  custom_name='Pipeline with Custom Component', random_seed=20)'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant