scipy icon indicating copy to clipboard operation
scipy copied to clipboard

MAINT: signal: rename `sosfreqz` to `freqz_sos`

Open luxedo opened this issue 1 year ago • 1 comments

Reference issue

Issue: https://github.com/scipy/scipy/issues/8319 Closes PR https://github.com/scipy/scipy/pull/8213

What does this implement/fix?

Rename sosfreqz to freqz_sos and keeps sosfreqz as an alias.

Additional information

I'd like to discuss three things:

  1. Should I place sosfreqz in the signa index? I think that the docs build fails if it's not there.
  2. I also placed a message just like the one at the end of interpolate for pchip. Is it necessary?

https://github.com/scipy/scipy/blob/776e64056f64bd70b503b7f8deb31fc155ac5c40/scipy/interpolate/init.py#L164-L165

  1. From #8213:

sosfilt sosfilt_zi sosfiltfilt should also be renamed by the same logic?

As soon as I have some feedback I wrap up the PR for merging.

luxedo avatar Jun 22 '24 22:06 luxedo

You can change it from single backticks (linking mode) to double backticks (code mode) in the 0.19 release notes.

larsoner avatar Jun 29 '24 16:06 larsoner

Hello! Any updates on this?

You can change it from single backticks (linking mode) to double backticks (code mode) in the 0.19 release notes.

Yes! It is done!

luxedo avatar Sep 02 '24 01:09 luxedo

I updated the documentation with your suggestions: https://github.com/scipy/scipy/pull/21025/files#diff-8a209fb35304df0e94887edfc436340479c2202ea7e37f7403e06135f823b093R117-R118

And I added a compatibility test similar to what's been done to other functions: https://github.com/scipy/scipy/pull/21025/files#diff-813f319a7ef4c294752f17de96f110c7e2d8cd6cbddbe3e73f2512917ad51ac7R946-R956

I had one fail from CI but it seems it was a network error: https://github.com/scipy/scipy/actions/runs/10675563135/job/29587743786?pr=21025

luxedo avatar Sep 03 '24 02:09 luxedo

Looks good! #8213 already had an approval and but needed a bit of extra work to get it over the finish line and that has now been done (and CIs are green; I restarted the one that had a timeout), so I'll go ahead and merge. Thanks @luxedo !

larsoner avatar Sep 03 '24 13:09 larsoner

Given that this is fresh in my head, I'll try to open PRs to standardize sosfilt sosfilt_zi sosfiltfilt as well.

@endolith in https://github.com/scipy/scipy/pull/8213#issuecomment-377970108

luxedo avatar Sep 03 '24 14:09 luxedo