Skip to content

Conversation

@saitcakmak
Copy link
Contributor

Summary:
Supports transforming ExperimentData with MetadataToFloat & MapKeyToFloat transforms. The transform constructor is also updated to support extracting the observations for the relevant parameters from experiment_data.

For MapKeyToFloat, the actual transform is no-op, since we have the map keys in observation_data and we can simply extract them from there in Adapter.

Background: As part of the larger refactor, we will be using ExperimentData in place of list[Observation] within the Adapter.

  • The transforms will be initialized using ExperimentData. The observations input to the constructors may be deprecated once the use cases are updated.
  • The training data for Adapter will be represented with ExperimentData and will be transformed using transform_experiment_data.
  • For misc input / output to various Adapter and other methods, the Observation / ObservationFeatures / ObservationData objects will remain. To support these, we will retain the existing transform methods that service these objects.
  • Since ExperimentData is not planned to be used as an output of user facing methods, we do not need to untransform it. We are not planning to implementuntransform_experiment_data.

Reviewed By: ltiao

Differential Revision: D76627256

Summary:
Supports transforming `ExperimentData` with `MetadataToFloat` & `MapKeyToFloat` transforms. The transform constructor is also updated to support extracting the observations for the relevant parameters from `experiment_data`.

For `MapKeyToFloat`, the actual transform is no-op, since we have the map keys in `observation_data` and we can simply extract them from there in `Adapter`.

Background: As part of the larger refactor, we will be using `ExperimentData` in place of `list[Observation]` within the `Adapter`.
- The transforms will be initialized using `ExperimentData`. The `observations` input to the constructors may be deprecated once the use cases are updated.
- The training data for `Adapter` will be represented with `ExperimentData` and will be transformed using `transform_experiment_data`.
- For misc input / output to various `Adapter` and other methods, the `Observation / ObservationFeatures / ObservationData` objects will remain. To support these, we will retain the existing transform methods that service these objects.
- Since `ExperimentData` is not planned to be used as an output of user facing methods, we do not need to untransform it. We are not planning to implement`untransform_experiment_data`.

Reviewed By: ltiao

Differential Revision: D76627256
@facebook-github-bot facebook-github-bot added the CLA Signed Do not delete this pull request or issue due to inactivity. label Jun 16, 2025
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D76627256

@codecov-commenter
Copy link

codecov-commenter commented Jun 16, 2025

Codecov Report

❌ Patch coverage is 98.59155% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 95.97%. Comparing base (28ad3d6) to head (a80737e).
⚠️ Report is 351 commits behind head on main.

Files with missing lines Patch % Lines
ax/adapter/transforms/map_key_to_float.py 88.88% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3934      +/-   ##
==========================================
- Coverage   95.97%   95.97%   -0.01%     
==========================================
  Files         554      554              
  Lines       55646    55691      +45     
==========================================
+ Hits        53405    53447      +42     
- Misses       2241     2244       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed Do not delete this pull request or issue due to inactivity. fb-exported

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants