Conversation
* New (consistent) convention: unless global is specified, all the attributes refer to local quantities * Pointing related functionalities moved to the scanning module
|
Thanks a lot, @dpole.
Regarding this, I believe it would be better for the moment to keep the class methods as tiny wrappers to the function, and to include a "deprecation" warning. A number of people are already using the scanning generator, and having warning messages would help them in porting the code. An example of a message could be the following: |
| from .distribute import distribute_evenly | ||
| from .scanning import Spin2EclipticQuaternions, all_compute_pointing_and_polangle | ||
|
|
||
| # NOTE: remove these imports after the deprecated methods have been removed |
There was a problem hiding this comment.
Wait, why should these imports be removed? They are referring to the functions, not to the methods of the Observation class, right?
There was a problem hiding this comment.
Yes, but once the deprecated methods are removed from Observation, they are not necessary anymore in this class. Right?
There was a problem hiding this comment.
Ok, but the comment is misleading, as it was placed above the exported functions, not the methods.
There was a problem hiding this comment.
Ah ok, now I see your point, I'll clarify.
| """ | ||
| logging.warn( | ||
| "Observation.get_quaternion_buffer_shape is deprecated and will be " | ||
| "removed soon, user scanning.get_quaternion_buffer_shape instead") |
There was a problem hiding this comment.
"user" -> "use" (the same typo happens below a few times)
|
I think this PR is ready to be merged, please feel free to comment, especially about the API. Note that the updated doc is already available here |
|
Great, thanks! Feel free to merge it, but first please add a note in file |
|
Ok, I will. I also noticed that there is problem with readthedocs. Building the documentation often (and unpredictably) results in the following error I would merge anyway because it is not a problem with the PR itself. |
|
The problem with Readthedocs is likely due to what was spotted in #89. |
This PR clarifies the documentation of the
Observationclass. It also changes its API for better clarity and coherency. As a part of this, al the pointing-related methods are turned into functions of thescanningmodule