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

Finish FlascDataFrame (Paul) #215

Merged
merged 14 commits into from
Oct 16, 2024
Merged

Conversation

paulf81
Copy link
Collaborator

@paulf81 paulf81 commented Oct 15, 2024

Finish FlascDataFrame

Type Hints

This PR goes through code and updates type hints and docstrings where pd.Dataframe is called for and adds the option for FlascDataFrame to be used as well to clarify code docs.

Note code mostly updates existing type hints, but where type hints aren't used updates docstrings. Getting to uniform type hinting and type hinting style can be a future project

Remove time requirement

Removes requirements time column is included, as this will necessarily be violated in certain conditions

Add test of FlascDataFrame driving energy ratio

Add a test that initiating an energy ratio analysis with FlascDataFrame is ok

Add test FlascDataFrame driving time operations

Add. to df_time_operations_test.py some additional testing ensuring matching results when using FlascDataFrame as input

@paulf81 paulf81 requested a review from misi9170 October 15, 2024 21:09
@paulf81 paulf81 changed the title Update type hints Finish FlascDataFrame (Paul) Oct 15, 2024
@paulf81 paulf81 merged commit faa6ee9 into NREL:flasc-dataframe Oct 16, 2024
3 checks passed
@paulf81 paulf81 deleted the feature/finish_fdf branch October 16, 2024 20:12
misi9170 added a commit that referenced this pull request Oct 17, 2024
* Add new `FlascDataFrame` object to enhance user interface with data (#199)

* Adding at the root level for now; could consider moving to utilities/

* Ruff.

* precommit stuff.

* Add example notebook

* Add wide to long

* Add test

* Update README.md engagement

* Update README.md replacing 'FLORIS' typo

* Feature/add docstrings (#197)

* Update to 15 (#202)

* Update for PyPI installation. (#204)

* Update version number; ignore version.py for ruff.

* Adhere to FLASC formatting rules.

* psuedocode for conversions. Tests for saving dataframe to file.

* Print warning when to_feather used.

* String formatting.

* Add several more tests and n_turbines property.

* Adding TODOs for long/wide conversions.

* Clean up, a few more tests.

* Improved printout.

* ruff format.

---------

Co-authored-by: Paul <paul.fleming@nrel.gov>
Co-authored-by: christiannvaughn <139596563+christiannvaughn@users.noreply.github.com>

* Add dataframe conversions to flascdataframe (#211)

* Add wind up example using `FlascDataFrame` (#210)

* loosen wind-up dependency

* Finish FlascDataFrame (Paul) (#215)

Add type hints

* Finish FlascDataFrame (update examples/docs) (#219)

* Merge recent changes.

* Update functions to use FlascDataFrames; getter and setter for channel_name_map; metadata copying method.

* Smarteole examples now using FlascDataFrame

* Add brief demonstration of switch to user data format; rename 09 notebook for clarity.

* Update artifical data examples.

* Had weird behavior in the getter/setter caused by not providing the true underlying attribute in _metadata.

* formatting.

* Simplify imports of FlascDataFrame throughout.

* Add wind-up to pyproject.toml after setup.py was removed.

* Update docs for FlascDataFrame (#220)

---------

Co-authored-by: misi9170 <39596329+misi9170@users.noreply.github.com>
Co-authored-by: christiannvaughn <139596563+christiannvaughn@users.noreply.github.com>
Co-authored-by: Alex Clerc <alex.clerc@res-group.com>
Co-authored-by: misi9170 <michael.sinner@nrel.gov>
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.

2 participants