3 ms·
This was a fascinating essay. Learning about the parallel array memory model, I immediately thought of its appropriateness for machine learning. I've just rece
by jackcosgrove 10y ago
This was a fascinating essay.
Learning about the parallel array memory model, I immediately thought of its appropriateness for machine learning. I've just recently started working with TensorFlow, and the syntax for memory allocation suggests that the values operated upon during a session are in parallel arrays. Of course TensorFlow is in Python, which would suggest a graph model, but it appears as if a parallel array memory model has been grafted onto a graph model.
Does anyone know if this is correct? And if so, is this memory allocated upon session start?
- pekk 10y agoThe internal representations of Python's core types are indeed pointer-heavy ("graph model"), and Python also encourages making references. But Python is not used like C, nor is it used exactly like Lisp; one does not usually increment loop variables, nor base everything on linked lists. If you are writing programs which use NumPy or TensorFlow heavily, you might actually be relying more on parallel array representations.
- lispm 10y ago> nor base everything on linked lists Lisp doesn't do that either.
- pg314 10y ago> nor base everything on linked lists. It seems your comment implies that Lisp bases everything on linked lists. That is a misconception. As early as Lisp 1.5 (1962), arrays were available (see section 4.4 of [1]). [1] http://www.softwarepreservation.org/projects/LISP/book/LISP%201.5%20Programmers%20Manual.pdf http://www.softwarepreservation.org/projects/LISP/book/LISP%...
- kazinator 10y agoMoreover, the submitted article itself makes it clear that when it says "LISP’s only data-structuring mechanism is something called a cons, which consists of two pointers" it is talking about Lisp 1.0. It also acknowledges that LISP is called Lisp now, too,