Skip to content

Make activation function configurable as argument#60

Merged
marianovitasari20 merged 12 commits intomainfrom
configurable-activation
Aug 19, 2025
Merged

Make activation function configurable as argument#60
marianovitasari20 merged 12 commits intomainfrom
configurable-activation

Conversation

@marianovitasari20
Copy link
Copy Markdown
Contributor

Previously, activation functions were hardcoded in the blocks.
Now they can be set via the configuration, allowing different models to use different activations without changing code.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Aug 15, 2025

Coverage report

Click to see where and how coverage changed

FileStatementsMissingCoverageCoverage
(new stmts)
Lines missing
  ice_station_zebra/models/common
  activations.py 1-3
  bottleneckblock.py 1-20
  convblock.py 1-32
  upconvblock.py 1-24
Project Total  

This report was generated by python-coverage-comment-action

@marianovitasari20 marianovitasari20 self-assigned this Aug 15, 2025
Copy link
Copy Markdown
Member

@jemrobinson jemrobinson left a comment

Choose a reason for hiding this comment

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

Could we change the type-signature of these modules to take str instead of the function itself? This makes it easier to serialise for checkpointing.

Comment thread ice_station_zebra/models/common/bottleneckblock.py Outdated
…guments when we instantiate it. This is necessary to reproduce previous behaviour.
@jemrobinson jemrobinson force-pushed the configurable-activation branch from 5448cac to 7f0def9 Compare August 19, 2025 09:24
Copy link
Copy Markdown
Member

@jemrobinson jemrobinson left a comment

Choose a reason for hiding this comment

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

LGTM

@marianovitasari20: I've replaced the get_activation function with a direct call to the dictionary, so we can pass arguments (like inplace=True) when we instantiate the classes, as was done before.

@marianovitasari20 marianovitasari20 merged commit ef5ad38 into main Aug 19, 2025
3 checks passed
@marianovitasari20 marianovitasari20 deleted the configurable-activation branch August 19, 2025 11:21
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