Releases: diffpy/diffpy.utils
Releases · diffpy/diffpy.utils
3.7.1
3.7.0
Added:
- Add
build_deprecation_messagehelper for printing consistent deprecation messages. - Add
generate_deprecation_docstringfor generating a template docstring for deprecated functions. - Support for Python 3.14
- Add
@deprecateddecorator. - Add documentation for calculation mu.
Changed:
- load_data now takes a Path or a string for the file-path
Deprecated:
- diffpy.utils.parsers.loaddata.loadData replaced by diffpy.utils.parsers.load_data
Fixed:
- Normalize paths before assert in
test_serialization/test_load_multipleto prevent possible Windows short/long name mismatch. - All references to
loadDatachanged toload_datadue to that deprecation
Removed:
- Removed API that calculates mu from packing fraction.
- Support for Python 3.11
3.7.0-rc.0
What's Changed
- Normalize paths before assert by @Tieqiong in #359
- fix: fix docstring to interpolate right entry. by @stevenhua0320 in #361
- fix: fix format of docstring to have no warning in html build by @stevenhua0320 in #362
- feat: add
@deprecateddecorator by @cadenmyers13 in #363 - fix: fix import to right file in examples by @stevenhua0320 in #364
- fix: fix deprecator to exactly match python 3.13 API by @cadenmyers13 in #366
- fix: add real data into example by @stevenhua0320 in #365
- feat: Deprecation message helper by @cadenmyers13 in #367
- scikit:recut diffpy.utils using latest scikit-package. by @stevenhua0320 in #369
- fix: Remove API for calculating mu from packing fraction by @cadenmyers13 in #370
- build: Add support for python 3.14 and drop for python 3.11 by @stevenhua0320 in #374
- deprecator by @sbillinge in #373
- depr tests by @sbillinge in #372
- docs: Mu calculation documentation by @cadenmyers13 in #375
- V3.7.0 by @cadenmyers13 in #377
- doc: Api docs for 3.7.0 by @cadenmyers13 in #379
- bug: docstring print statement bug by @cadenmyers13 in #380
New Contributors
- @stevenhua0320 made their first contribution in #361
Full Changelog: 3.6.1...3.7.0-rc.0
3.6.1
Added:
- update isort, flake8 and black to set line limit to 79
Fixed:
- Support
scikit-packageLevel 5 standard (https://scikit-package.github.io/scikit-package/). - Update github CI to scikit-package standard
- Let
DiffractionObject.get_array_indexto use thextypefrom its inputs.
Removed:
- Extra line break in each news after 3.6.0 in
CHANGELOG.rstso that this rst can be rendered correctly when deployed
3.6.1-rc.1
What's Changed
- style: update to
CODE-OF-CONDUCT.rst,requirements/tests.textanddocs/according to new group standard. by @ycexiao in #351 - docs: fix the example of using
DiffractionObject.get_array_indexin the documentation by @ycexiao in #354 - Fix: let
DiffractionObject.get_array_indexto usextypefrom its inputs. by @ycexiao in #356 - docs: fix the
diffpy.utils.transforms.d_to_tthexample by @ycexiao in #357
Full Changelog: 3.6.1-rc.0...3.6.1-rc.1
3.6.1-rc.0
What's Changed
- docs: remove extra line break in 3.6.0 changelog.rst by @bobleesj in #317
- chore: synchronize readme and index of docs by @sbillinge in #318
- update flake8, black and isort to set line length limit to 79 by @ycexiao in #326
- skpkg: update github workflows to skpkg standards by @cadenmyers13 in #341
- skpkg: doc migration by @cadenmyers13 in #342
- skpkg: misc config and other file changes by @cadenmyers13 in #344
- skpkg: merge
migrationbranch intomainby @cadenmyers13 in #346
New Contributors
Full Changelog: 3.6.0...3.6.1-rc.0
3.6.0
Added:
- unit tests for initializing DiffractionObject with empty array in xarray and yarray
- function to return the index of the closest value to the specified value in an array.
- functions to convert between d and q
- catch division by zero warning messages in tests
- functionality to raise useful warning and error messages during angular conversion between two theta and q
- Improved API documentation in
DiffractionObjectmethods and properties using the NumPy docstring format and PEP 256 - validate xtype belongs to XQUANTITIES during DiffractionObject init
- Group's Pytest practices for using @pytest.mark.parametrize in test_diffraction_objects.py
- unit tests for add operation for DiffractionObject
- Better wording on the capture user info functionality
- Spelling check via Codespell in pre-commit
- prettier pre-commit hook for automatic linting of .yml, .json, and .md files
- Function that can be used to compute muD (absorption coefficient) from a file containing an absorption profile
from a line-scan through the sample - sbillinge username as the authorized admin for GitHub release workflow in
build-wheel-release-upload.yml - function to compute x-ray attenuation coefficient (mu) using XrayDB
- class docstring for
DiffractionObject - docforamtter in pre-commit for automatic formatting of docstrings to PEP 257
- Function nsinterp for automatic interpolation onto the Nyquist-Shannon grid.
- functionality to return the 2D array based on the specified xtype
- functionality in dump to allow writing data on dspace
- addition, multiplication, subtraction, and division operators between two DiffractionObject instances or a scalar value with another DiffractionObject for modifying yarray (intensity) values.
- functionality to rescale diffraction objects, placing one on top of another at a specified point
- new feature in
scale_to(): default scaling is based on the max q-value in each diffraction object. - functions to convert between d and tth
- unit test for expected warning when no wavelength is provided for DiffractionObject init
- copy() method for DiffractionObject instance
- docstrings for
on_q,on_tth,on_d, anddumpindiffraction_objects.py. - prevent direct modification of
all_arraysusing@property - Information on how to update the default user information
- Example docs for basic DiffractionObject usage
- deploy github pages documentation on pre-release
- Gettable
idproperty toDiffractionObject
Changed:
- Refactor get_user_info to separate the tasks of getting the info from config files
and creating config files when they are missing. - test comment format with compact style without extra line for each comment
- Rename
input_scattering_quantitytoinput_datainDiffractionObjectinit - refactor
q_to_tth()andtth_to_q()intodiffpy.utils.transformsto make them available outside
DiffractionObject - Moved resampler out of parsers, new path is diffpy.utils.resampler
- Rename the
isfloatfunction tois_number, and move it to thediffpy/utils/utilsvalidators.pydirectory - arrays and attributes now can be inserted when a DiffractionObject is instantiated
- data are now stored as a (len(x),4) numpy array with intensity in column 0, the q, then tth, then d
DiffractionObject.on_q,...on_tthand...on_dare now methods and called asDiffractionObject.on_q()etc.`- \tests directory tree to match \src
- DiffractionObject's "id" property renamed to "uuid"
DiffractionObjectrequires 3 input parameters ofxarray,yarray,xtype, to be instantiated. It can be instantiated with empty arrays.- Paths in our documentation reflect changes made in code.
- Enumerated list for the different ways to set user information
Deprecated:
resamplefunction in resampler. Replaced withwsinterpwith better functionality.- Diffraction_object class, renamed to DiffractionObject
Fixed:
- additional information to users to relieve frustration in finding how to update global config
- Unittest to Pytest migration for test_loaddata.py
- file paths of the test files according to new \tests directory tree
- Typo for get_package_info example
- return type of
get_array_indexmethod inDiffractionObjectto return integer instead of list
Removed:
- scattering_objects layer in importing diffraction_objects
user_config.py. Replaced by_load_configandcheck_and_build_global_configintools.py.- Relative imports in parser's init.py
set_angles_from_list,set_angles_from,set_qs_from_rangemethods inDiffractionObject
3.6.0rc4
What's Changed
- doc: simon tweaks on the docs before release by @sbillinge in #315
Full Changelog: 3.6.0rc2...3.6.0rc4
3.6.0rc3
What's Changed
Full Changelog: 3.6.0rc0...3.6.0rc3
3.6.0rc2
What's Changed
Full Changelog: 3.6.0rc0...3.6.0rc2