Skip to content

Conversation

moritzmeister
Copy link
Contributor

Moving feature groups into single module to resolve circular imports.
Also moving all query constructor related classes into separate package.



class FeatureGroup(feature_group_base.FeatureGroupBase):
class FeatureGroupBase:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand this refactor. Why putting everything on a single file?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not a huge fan either, but somehow I was getting circular imports because I created the new constructor package. It's quite a pain to debug those, so I can try and find a different solution, but this was the most obvious fix.

```python
# create a query
feature_join = rain_fg.select_all()
.join(temperature_fg.select_all(), on=["date", "location_id"])
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd keep this first example simple and also mention how the joining key is selected.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added more examples also with scala equivalents.

@SirOibaf SirOibaf merged commit 0130182 into logicalclocks:master Dec 22, 2020
@moritzmeister moritzmeister deleted the HOPSWORKS-2134 branch December 22, 2020 14:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request python

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants