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

Add primitive.get_filepath and example of primitive loading data from external files #380

Merged
merged 16 commits into from Jan 29, 2019

Conversation

rwedge
Copy link
Contributor

@rwedge rwedge commented Jan 24, 2019

This PR adds the method PrimitiveBase.get_filepath. This helper function creates an absolute file path by joining the path to featuretools/primitives/data with the filename supplied by the user.

@codecov
Copy link

codecov bot commented Jan 24, 2019

Codecov Report

Merging #380 into master will increase coverage by 0.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #380      +/-   ##
==========================================
+ Coverage   95.84%   95.85%   +0.01%     
==========================================
  Files          89       89              
  Lines        7769     7798      +29     
==========================================
+ Hits         7446     7475      +29     
  Misses        323      323
Impacted Files Coverage Δ
...s/tests/primitive_tests/test_transform_features.py 98.03% <100%> (+0.1%) ⬆️
featuretools/primitives/base/primitive_base.py 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e8d6278...4004812. Read the comment docs.


def test_get_data_path(es):
class Mod4(TransformPrimitive):
'''Replace each integer with a word from a shakespearean sonnet'''
Copy link
Contributor

@kmax12 kmax12 Jan 25, 2019

Choose a reason for hiding this comment

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

is this docstring accurate?

@rwedge rwedge changed the title Add primitive.get_data_path and example of primitive loading data from external files Add primitive.get_filepath and example of primitive loading data from external files Jan 29, 2019
Copy link
Contributor

@kmax12 kmax12 left a comment

Choose a reason for hiding this comment

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

Looks good to merge

@rwedge rwedge merged commit 575fced into master Jan 29, 2019
@rwedge rwedge mentioned this pull request Jan 30, 2019
@rwedge rwedge deleted the primitives-load-from-file branch February 19, 2021 21:29
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 this pull request may close these issues.

None yet

2 participants