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

Fix reqs and ModelInterface sample_data #32

Merged
merged 45 commits into from
Jul 29, 2024
Merged

Fix reqs and ModelInterface sample_data #32

merged 45 commits into from
Jul 29, 2024

Conversation

thorrester
Copy link
Member

@thorrester thorrester commented Jul 24, 2024

Pull Request

Short Summary

Reqs

Updating reqs to handle latest tensorflow version and fiasco. Tensorflow moved to a keras 3 backend which has broken a few things when it comes to architecture compatibility.

HuggingFace has not updated their library to handle Keras 3, so we need to install tf-keras for the time being for backward compatibility. This works on linux, but this appears to prevent tensorflow from running on macos. There's also issues with arm at the moment. We'll need to keep an eye out.

ModelInterface

sample_data is currently saved as a joblib artifact. A better solution would be to put the provided sample_data into a DataInterface class and save the data as it's associated library intends. To do this, we had to add in some logic that attempts to determin if the provided data is one of the support DataInterface subclasses. If so, the data is added to the interface and the interface is added to sample_data attribute. If interface is not determined, logic falls back to joblib. Saving and loading data have been updated as well.

Copy link

github-actions bot commented Jul 24, 2024

Dependency Review

The following issues were found:
  • ✅ 0 vulnerable package(s)
  • ✅ 0 package(s) with incompatible licenses
  • ✅ 0 package(s) with invalid SPDX license definitions
  • ⚠️ 2 package(s) with unknown licenses.
See the Details below.

License Issues

poetry.lock

PackageVersionLicenseIssue Type
namex0.0.8NullUnknown License

pyproject.toml

PackageVersionLicenseIssue Type
polars^ 1.0.0NullUnknown License

Scanned Manifest Files

.github/workflows/lint-unit-tests.yml
  • homebrew/actions/setup-homebrew@master
poetry.lock
  • gast@0.6.0
  • google-auth-oauthlib@1.2.1
  • keras@3.4.1
  • ml-dtypes@0.3.2
  • namex@0.0.8
  • numpy@1.26.4
  • optree@0.12.1
  • polars@1.3.0
  • pymdown-extensions@10.9
  • regex@2024.7.24
  • scouter-ml@0.2.4rc3
  • sentence-transformers@3.0.1
  • tensorboard@2.16.2
  • tensorflow@2.16.2
  • tf-keras@2.16.0
  • wrapt@1.16.0
  • asn1crypto@1.5.1
  • cffi@1.16.0
  • cloud-sql-python-connector@1.11.0
  • cryptography@43.0.0
  • dacite@1.8.1
  • gast@0.4.0
  • google-auth-oauthlib@1.0.0
  • htmlmin@0.1.12
  • imagehash@4.3.1
  • jax@0.4.17
  • jax@0.4.30
  • jaxlib@0.4.30
  • keras@2.12.0
  • llvmlite@0.43.0
  • ml-dtypes@0.3.1
  • ml-dtypes@0.4.0
  • multimethod@1.12
  • numba@0.60.0
  • numpy@1.23.5
  • pandas@2.1.0
  • patsy@0.5.6
  • pg8000@1.31.2
  • phik@0.12.4
  • polars@0.18.15
  • pycparser@2.22
  • pymdown-extensions@10.8.1
  • pywavelets@1.6.0
  • regex@2024.5.15
  • scramp@1.4.5
  • seaborn@0.13.2
  • statsmodels@0.14.0
  • statsmodels@0.14.2
  • tensorboard@2.12.3
  • tensorflow@2.12.0
  • tensorflow-estimator@2.12.0
  • tensorflow-macos@2.12.0
  • typeguard@4.3.0
  • visions@0.7.6
  • wordcloud@1.9.3
  • wrapt@1.14.1
  • ydata-profiling@4.9.0
pyproject.toml
  • polars@^ 1.0.0
  • scouter-ml@^ 0.2.4rc3
  • streaming-form-data@>= 1.11.0,< 1.16.0
  • cloud-sql-python-connector@^ 1.2.0
  • pg8000@^ 1.29.4
  • polars@^ 0.18.0
  • streaming-form-data@^ 1.11.0
  • ydata-profiling@^ 4.6.1

Copy link

codecov bot commented Jul 28, 2024

Codecov Report

Attention: Patch coverage is 79.75904% with 84 lines in your changes missing coverage. Please review.

Project coverage is 91.10%. Comparing base (2e88ebc) to head (104649e).

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #32      +/-   ##
==========================================
- Coverage   91.51%   91.10%   -0.41%     
==========================================
  Files         115      115              
  Lines        9213     9374     +161     
==========================================
+ Hits         8431     8540     +109     
- Misses        782      834      +52     
Files Coverage Δ
opsml/data/interfaces/_arrow.py 100.00% <100.00%> (ø)
opsml/data/interfaces/_numpy.py 100.00% <100.00%> (ø)
opsml/data/interfaces/_pandas.py 100.00% <100.00%> (ø)
opsml/data/interfaces/_polars.py 100.00% <100.00%> (ø)
opsml/helpers/utils.py 98.26% <ø> (ø)
opsml/model/interfaces/lgbm.py 95.31% <100.00%> (-0.08%) ⬇️
opsml/model/interfaces/sklearn.py 89.79% <100.00%> (-0.21%) ⬇️
opsml/model/interfaces/tf.py 86.66% <100.00%> (-1.18%) ⬇️
opsml/model/interfaces/vowpal.py 90.74% <100.00%> (-0.34%) ⬇️
opsml/model/metadata_creator.py 67.39% <ø> (ø)
... and 20 more

... and 2 files with indirect coverage changes

@thorrester thorrester changed the title Fix reqs Fix reqs and ModelInterface sample_data Jul 28, 2024
@thorrester thorrester marked this pull request as ready for review July 29, 2024 10:38
@thorrester thorrester merged commit ce806a6 into main Jul 29, 2024
15 checks passed
@thorrester thorrester deleted the fix-reqs branch August 16, 2024 14:22
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.

1 participant