Skip to content

Conversation

@caioolivv
Copy link
Collaborator

No description provided.

@caioolivv caioolivv requested a review from m-aguena February 5, 2025 21:52
@caioolivv caioolivv self-assigned this Feb 5, 2025
@coveralls
Copy link

coveralls commented Feb 5, 2025

Coverage Status

coverage: 100.0%. remained the same
when pulling 03ae4d0 on issue/658/api_break_for_numcosmo
into 86faa10 on main.

@m-aguena m-aguena linked an issue Sep 12, 2025 that may be closed by this pull request
@m-aguena
Copy link
Member

Hi @caioolivv can you check these changes are still valid? I installed the new version of numcosmo (numcosmo-0.24.0) and got the error

AttributeError: 'gi.repository.NumCosmo' object has no attribute 'HaloDensityProfileMassDef'

@m-aguena m-aguena force-pushed the issue/658/api_break_for_numcosmo branch from da214e7 to bf682a2 Compare September 12, 2025 16:31
@caioolivv
Copy link
Collaborator Author

Hi @m-aguena, I couldn't reproduce it. What exactly did you run that ended up on this error? I ran all notebooks that use NumCosmo and they are mostly fine (with exception of a function HICosmo.new_from_name() that was deprecated a couple of years ago and wasn't updated).

@m-aguena
Copy link
Member

Hi @m-aguena, I couldn't reproduce it. What exactly did you run that ended up on this error? I ran all notebooks that use NumCosmo and they are mostly fine (with exception of a function HICosmo.new_from_name() that was deprecated a couple of years ago and wasn't updated).

@caioolivv my impression is that somehow an older version of numcosmo is being used, even though I installed it from scrach on a new computer. Which version fo numcosmo are you using here?

@caioolivv
Copy link
Collaborator Author

I was using numcosmo 0.24.0, but 0.25.0 has just been pushed. I'll have to test with the new version.

Copy link
Member

@m-aguena m-aguena left a comment

Choose a reason for hiding this comment

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

@caioolivv thanks for the work! It seems the changes are working now, but the Example2_Fit_Halo_Mass_to_Shear_Catalog_NC.ipynb notebook is still failing:

AttributeError: 'NoneType' object has no attribute 'mid'

@caioolivv
Copy link
Collaborator Author

@caioolivv thanks for the work! It seems the changes are working now, but the Example2_Fit_Halo_Mass_to_Shear_Catalog_NC.ipynb notebook is still failing:

AttributeError: 'NoneType' object has no attribute 'mid'

Just fixed it, but that reminds me of two things:

  1. I've just updated for numcosmo<=0.24. Versions 0.25 and up have a different problem that I'll have to think about... in another PR.
  2. This Example2_Fit_Halo_Mass_to_Shear_Catalog_NC.ipynb notebook contains an old unbinned likelihood model that has been completely reworked to a new version we've discussed adding to a fitting module in CLMM. I think we leave this as is at the moment and edit it only when we decide how to add the new unbinned likelihood method.

@github-actions github-actions bot changed the title Issue/658/api break for numcosmo Issue/658/api break for numcosmo [version:1.16.8] Dec 3, 2025
@github-actions github-actions bot changed the title Issue/658/api break for numcosmo [version:1.16.8] Issue/658/api break for numcosmo [version:1.16.9] Dec 3, 2025
@m-aguena
Copy link
Member

m-aguena commented Dec 3, 2025

@caioolivv thanks for the work! It seems the changes are working now, but the Example2_Fit_Halo_Mass_to_Shear_Catalog_NC.ipynb notebook is still failing:

AttributeError: 'NoneType' object has no attribute 'mid'

Just fixed it, but that reminds me of two things:

  1. I've just updated for numcosmo<=0.24. Versions 0.25 and up have a different problem that I'll have to think about... in another PR.
  2. This Example2_Fit_Halo_Mass_to_Shear_Catalog_NC.ipynb notebook contains an old unbinned likelihood model that has been completely reworked to a new version we've discussed adding to a fitting module in CLMM. I think we leave this as is at the moment and edit it only when we decide how to add the new unbinned likelihood method.

Agreed, can you create an issue to remember of revisiting Example2_Fit_Halo_Mass_to_Shear_Catalog_NC.ipynb in the future? Thanks

Copy link
Member

@m-aguena m-aguena left a comment

Choose a reason for hiding this comment

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

Thanks for handling this!

@caioolivv caioolivv merged commit 9c52414 into main Dec 3, 2025
5 checks passed
@caioolivv caioolivv deleted the issue/658/api_break_for_numcosmo branch December 3, 2025 23:01
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.

Update API for NumCosmo>v0.22.0

5 participants