seq-like methods in Transpose? (Migrating from Scalala to Breeze)

26 lượt xem
Chuyển tới thư đầu tiên chưa đọc

Juan Miguel Cejuela

chưa đọc,
12:54:57 23 thg 7, 201523/7/15
đến Scala Breeze

Hi group,

I’m migrating a third-party library that used scalala to breeze. Before row vectors were used extensively. From the quick start I read that row vectors are now Transposes of vectors in scala.

When I do the pertinent type changes, compilation problems arise since it seems a Transpose doesn’t implement (mutable) sequence methods, such as: update, max, argmax, toArray, …

Am I missing something? Is there any implicit that I should include?

Thanks!

David Hall

chưa đọc,
14:00:05 23 thg 7, 201523/7/15
đến scala-...@googlegroups.com
Yeah, you basically have to unwrap the transposes with .t.

I'm starting to regret the whole Transpose thing. 90% of the reason for its existence was to make dv.t * dv be dot product without having two DenseVector types lying around, which was a huge maintenance headache.  

I think I have a better solution now (using a type parameter on DenseVector and adding aliases) but it'll take a lot of cycles.

-- David

--
You received this message because you are subscribed to the Google Groups "Scala Breeze" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scala-breeze...@googlegroups.com.
To post to this group, send email to scala-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/scala-breeze/de2c5b1e-611b-4744-9115-a853a9438317%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Trả lời tất cả
Trả lời tác giả
Chuyển tiếp
0 tin nhắn mới