Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added ARCHITECTURE.md #471

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open

Added ARCHITECTURE.md #471

wants to merge 7 commits into from

Conversation

chewxy
Copy link
Member

@chewxy chewxy commented Feb 9, 2021

No description provided.


Hence for simplicity's sake, there is no difference between an operator and a function in Gorgonia. They are all treated as functions, but named `Op`. The `Op`s in Gorgonia may be found in files starting with `op_`.

The definition of the `Op` interface may be found in `op.go`.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The definition of the `Op` interface may be found in `op.go`.
The definition of the [`Op`](https://pkg.go.dev/gorgonia.org/gorgonia#Op) interface may be found in `op.go`.


Hence when we perform a symbolic differentiation, we're adding new `*Node`s to the graph, each representing a partial derivative of ![c](https://render.githubusercontent.com/render/math?math=%5Ctextstyle+c) with regards to ![a](https://render.githubusercontent.com/render/math?math=%5Ctextstyle+a) or ![b](https://render.githubusercontent.com/render/math?math=%5Ctextstyle+b).

An `Op` that supports symbolic differentiation must implement `SDOp`.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
An `Op` that supports symbolic differentiation must implement `SDOp`.
An `Op` that supports symbolic differentiation must implement [`SDOp`](https://pkg.go.dev/gorgonia.org/gorgonia#SDOp).


To aid in automatic differentiation, a `dualValue` type is also used. A `*dualValue` is exactly what it suggests: a value that contains two values - usually the value and a gradient.

An `Op` that supports automatic differentiation must implement `ADOp`.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
An `Op` that supports automatic differentiation must implement `ADOp`.
An `Op` that supports automatic differentiation must implement [`ADOp`](https://pkg.go.dev/gorgonia.org/gorgonia#ADOp).

TODO

### `*goMachine` ###
TODO
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
TODO
The GoMachine is documented on Gorgonia's website [gorgonia.org/reference/vm/gomachine/](https://gorgonia.org/reference/vm/gomachine/)

@owulveryck
Copy link
Member

This is a general comment about the name (and naming is hard).
Architecture is about the important stuff, whatever it is. Nevertheless, in our context, naming this doc ARCHITECTURE is a bit misleading for the user.

As I don't have any other relevant name to offer, I propose to move this document to a docs folder.
People seeking documentation will go there and open the only doc present (whatever its name), and somehow, once we have other exciting stuff to put there, we can rename ARCHITECTURE.md

@chewxy
Copy link
Member Author

chewxy commented Feb 15, 2021

README.md in the docs folder?

@codecov
Copy link

codecov bot commented Feb 15, 2021

Codecov Report

Merging #471 (a0c6e8c) into master (0526c98) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #471   +/-   ##
=======================================
  Coverage   55.41%   55.41%           
=======================================
  Files          71       71           
  Lines       11597    11597           
=======================================
  Hits         6426     6426           
  Misses       4324     4324           
  Partials      847      847           
Flag Coverage Δ
unittests 55.41% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.


Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0526c98...a0c6e8c. Read the comment docs.

@dcu
Copy link
Collaborator

dcu commented Mar 28, 2021

what about DESIGN.md ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants