Enjoyed <@U5F0TT0UX>’s talk, especially the use of...
# datascience
b
Enjoyed @altavir’s talk, especially the use of generics and scoping for type safe numerics:

https://youtube.com/watch?v=LI_5TZ7tnOE

👍 6
a
It is the new development, but the more I think about, the more I like it.
I believe that the core should be generic, it is also possible to add user-side extensions for more comfortable specialized experience: https://github.com/mipt-npm/kmath/tree/dev-pk/kmath-for-real (It probably needs to be adopted for the latest API).
The extension for real numbers is done by @Peter Klimai. I need to pull it into dev soon. But any feedback is appreciated. Specifically from @thomasnield since he requested them in the first place.
b
It may be possible to avoid nesting by wrapping the context inside a monad, less verbose although less explicit
Kind of like this, but for arithmetic operations: https://kotlin.christmas/2019/17/
a
Nesting is important here since one context generates another one. In order to get ND context for Complex numbers, you need to get ComplexField. So either you pass it as parameter to ND context constructor, or you can capture it from the external context.
File-level contexts (https://github.com/Kotlin/KEEP/pull/176#issuecomment-460148157) would solve the issue. But even if they are accepted, it is a long wait.