Skip to content

Conversation

@dan-zheng
Copy link
Contributor

Add AnyDifferentiable, a type-erased wrapper for Differentiable-conforming types.
Depends on #30926.


Motivating use case from @marcrasi:

https://github.com/borglab/SwiftFusion wants to let the user define a collection of variables of arbitrary types and construct loss functions over those variables.

@dan-zheng dan-zheng requested review from marcrasi and rxwei April 9, 2020 20:04
@dan-zheng dan-zheng force-pushed the any-differentiable branch from 4f8b866 to 6ebf5c9 Compare April 9, 2020 20:17
Copy link

@marcrasi marcrasi left a comment

Choose a reason for hiding this comment

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

More details about the SwiftFusion motivating use case: borglab/SwiftFusion#11 (comment)

@dan-zheng dan-zheng changed the title [AutoDiff upstream] Add AnyDifferentiable. [AutoDiff] Add AnyDifferentiable. Apr 9, 2020
@dan-zheng dan-zheng force-pushed the any-differentiable branch from 6ebf5c9 to 1bfc0a3 Compare April 9, 2020 20:28
Add `AnyDifferentiable`, a type-erased wrapper for `Differentiable`-conforming types.
@dan-zheng dan-zheng force-pushed the any-differentiable branch from 1bfc0a3 to f073ef5 Compare April 9, 2020 21:42
@dan-zheng
Copy link
Contributor Author

@swift-ci Please test

@swift-ci
Copy link
Contributor

swift-ci commented Apr 9, 2020

Build failed
Swift Test Linux Platform
Git Sha - f073ef5

@dan-zheng
Copy link
Contributor Author

@swift-ci Please test Linux

@swift-ci
Copy link
Contributor

Build failed
Swift Test Linux Platform
Git Sha - f073ef5

@dan-zheng
Copy link
Contributor Author

The Linux failure appears unrelated.
@swift-ci Please smoke test Linux

@dan-zheng dan-zheng merged commit 3ef8360 into swiftlang:master Apr 10, 2020
@dan-zheng dan-zheng deleted the any-differentiable branch April 10, 2020 05:49
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.

4 participants