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

Cumsum cumprod #492

Merged
merged 6 commits into from
Jan 20, 2021
Merged

Cumsum cumprod #492

merged 6 commits into from
Jan 20, 2021

Conversation

filipeclduarte
Copy link
Contributor

Following the issue: #491 @HugoGranstrom helped me develop those two procedures: cumsum and cumprod, which are very useful to scientific computing and finance.

@mratsim
Copy link
Owner

mratsim commented Jan 5, 2021

Thanks! Can you add a test in the test suite?

Ultimately we likely want that parallelized and a test would be helpful to ensure that we don't mess it up.

@filipeclduarte
Copy link
Contributor Author

I added the test for these procedures. I'm gonna commit the changes.

Copy link
Owner

@mratsim mratsim left a comment

Choose a reason for hiding this comment

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

Nim's early symbol resolution strikes again :/ nim-lang/Nim#8677 nim-lang/Nim#6387

## - t: a rank-n tensor to cumulatively sum
## - axis: int
## Returns:
## - A tensor cumulatively summed at axis, that is, add each value to
Copy link
Owner

Choose a reason for hiding this comment

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

can you add mixin _ here, it seems like the _ symbol is not visible in some cases and breaks CI

Copy link
Contributor Author

Choose a reason for hiding this comment

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

added

## - t: a rank-n tensor to cumulatively sum
## - axis: int
## Returns:
## - A tensor cumulatively summed at axis, that is, add each value to
Copy link
Owner

Choose a reason for hiding this comment

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

and similar here can you add mixin _ here, it seems like the _ symbol is not visible in some cases and breaks CI

Copy link
Contributor Author

Choose a reason for hiding this comment

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

added

@mratsim mratsim merged commit 71cf616 into mratsim:master Jan 20, 2021
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.

2 participants