I realized I don't do this consistently. I have
matrix_from_scores(), etc. Is there a good convention for this?
The most important convention is to be consistent.
The next most important thing is to be readable. I consider "A to B" more intellegible, since A precedes B both in the name and in the execution flow, while "B from A" reverses the association.
(This concerns the names of free functions. If you're writing methods, then you might be forced to write both an "Address.fromString(s)" and an "Address.toString()" if there is an existing policy about creation methods.)