Alexander Nozik

Results 249 comments of Alexander Nozik

I see the idea, but parallel is not necessary concurrent. On the contrary, in my example, there is no concurrency. The key feature needed for parallel `map` is an ability...

I won't argue with you about the terminology, especially remembering that significant fraction of my knowledge of it comes from your articles. Still, it does not change the fact that...

The problem was in the conflict of lazy deferred with structured concurrency. I've fixed it by replacing deferred by my imitation. The working code is available [here](https://github.com/mipt-npm/kmath/blob/d138ce38898e54ff78959591a7e44ee124384201/kmath-coroutines/src/commonMain/kotlin/scientifik/kmath/CoroutinesExtra.kt#L59). In theory, it...

The particular case is a streaming mathematical processor with ability to parallel computations. In the version before the `Flow` I had Producers - generators, which could lazily create elements of...

@qwwdfsad Seems to be working. I looked into the source and it does the trick with two channels I was intending to do. I've changed signature a bit: `fun Flow.map(concurrencyLevel:...

I like the idea (the radical one) in general. The `flatMapMerge` is really vague. It is hard to understand what it does and how its parameters affect the result. The...

@sdeleuze You need to convert your flow to "promises" at some point and then another point to actualize those promises. In between those points you have concurrency. So you always...

> I think that `concurrent()` shall return a special `ConcurrentFlows` My thought exactly. [This way](https://github.com/mipt-npm/kmath/blob/fcab05b683aa6d12e688ca9d285949dd7db4247a/kmath-coroutines/src/commonMain/kotlin/scientifik/kmath/CoroutinesExtra.kt#L25) it could even inherit `Flow` and be collected in a sequential way, though, I am...

> It is not what `concurrent().map { ... }.merge()` would be doing, since that operator chain reorders original flow just like `flatMapMerge` is doing now I do not think it...

Additional complication could come from the fact that different implementations could have different rules about text representation for JSON