Skip to content

Adopt dream code temporal conv module#1

Open
Entr000py wants to merge 2 commits intomainfrom
codex/integrate-temporal_conv-before-self.w
Open

Adopt dream code temporal conv module#1
Entr000py wants to merge 2 commits intomainfrom
codex/integrate-temporal_conv-before-self.w

Conversation

@Entr000py
Copy link
Owner

Summary

  • replace models/temporal_conv.py with the original implementation from dream_code_v3/3_5_Temporal_conv.py so it matches the reference module verbatim
  • update PaiFilter to import and instantiate the lowercase temporal_conv class provided by the copied module

Testing

  • python -m compileall models

Codex Task

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +21 to +27
temporal_channels = max(1, getattr(configs, "temporal_conv_channels", 4))
temporal_dilation = max(1, getattr(configs, "temporal_conv_dilation", 1))
self.temporal_conv = temporal_conv(
cin=1,
cout=temporal_channels,
dilation_factor=temporal_dilation,
seq_len=self.seq_len,

Choose a reason for hiding this comment

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

P1 Badge 校验 temporal_conv 通道数避免生成 0 输出通道

这里将 temporal_channels 仅限制为 >=1 后直接传给 temporal_conv。而该模块内部在 dilated_inception 中会用 len(kernel_set)=4 整除 cout 并据此创建四个 nn.Conv2d。当配置文件把 temporal_conv_channels 设为 1~3 时,整除后的通道数变成 0,使卷积层初始化时触发 out_channels must be > 0 的异常,模型无法构建。应至少将该超参约束在 4 及其倍数范围内,或者在构造前做显式校验。

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant