nerdexam
Google

PROFESSIONAL-DATA-ENGINEER · Question #172

You're training a model to predict housing prices based on an available dataset with real estate properties. Your plan is to train a fully connected neural net, and you've discovered that the…

The correct answer is C. Create a feature cross of latitude and longitude, bucketize at the minute level and use L1 regularization during optimization. Explanation/Reference: Use L1 regularization when you need to assign greater importance to more influential features. It shrinks less important feature to 0. L2 regularization performs better when all input features influence the output & all with the weights are of equal size.

Submitted by katya_ua· Mar 30, 2026Operationalizing machine learning models

Question

You're training a model to predict housing prices based on an available dataset with real estate properties. Your plan is to train a fully connected neural net, and you've discovered that the dataset contains latitude and longitude of the property. Real estate professionals have told you that the location of the property is highly influential on price, so you'd like to engineer a feature that incorporates this physical dependency. What should you do?

Options

  • AProvide latitude and longitude as input vectors to your neural net.
  • BCreate a numeric column from a feature cross of latitude and longitude.
  • CCreate a feature cross of latitude and longitude, bucketize at the minute level and use L1 regularization during optimization.
  • DCreate a feature cross of latitude and longitude, bucketize it at the minute level and use L2 regularization during optimization.

How the community answered

(36 responses)
  • A
    31% (11)
  • B
    8% (3)
  • C
    44% (16)
  • D
    17% (6)

Explanation

Explanation/Reference: Use L1 regularization when you need to assign greater importance to more influential features. It shrinks less important feature to 0. L2 regularization performs better when all input features influence the output & all with the weights are of equal size.

Topics

#feature engineering#feature cross#bucketization#L2 regularization

Community Discussion

No community discussion yet for this question.

Full PROFESSIONAL-DATA-ENGINEER Practice