Skip to content

Commit

Permalink
#162 Merge pull request from deshima-dev/astropenguin/issue161
Browse files Browse the repository at this point in the history
Fix timezone-dependent datetime parsing
  • Loading branch information
astropenguin authored Jul 26, 2024
2 parents 12053cf + 28c7a23 commit bebba98
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 11 deletions.
4 changes: 2 additions & 2 deletions CITATION.cff
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,5 @@ keywords:
- spectroscopy
- deshima
license: MIT
version: 2024.7.2
date-released: '2024-07-22'
version: 2024.7.3
date-released: '2024-07-27'
11 changes: 6 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ DESHIMA merge code for observed datasets
## Installation

```shell
pip install demerge==2024.7.2
pip install demerge==2024.7.3
```

## Command line interface
Expand All @@ -37,18 +37,19 @@ FLAGS
--data_dir=DATA_DIR
Type: Path
Default: PosixPath('.')
Path where raw data directory is placed,
Path of directory where data packages are placed,
i.e. expecting ``${data_dir}/cosmos_YYYYmmddHHMMSS``.
--dems_dir=DEMS_DIR
Type: Path
Default: PosixPath('.')
Path where merged DEMS file will be placed,
Path of directory where merged DEMS will be placed,
i.e. expecting ``${dems_dir}/dems_YYYYmmddHHMMSS.zarr.zip``.
--reduced_dir=REDUCED_DIR
Type: Path
Default: PosixPath('.')
Path where reduced data directory will be placed,
Path of directory where reduced packages are placed,
i.e. expecting ``${reduced_dir}/reduced_YYYYmmddHHMMSS``.
If not specified, a temporary directory will be used.
--ddb=DDB
Type: Path
Default: PosixPath('/path/to/demerge/data/ddb_20240713.fits')
Expand All @@ -60,7 +61,7 @@ FLAGS
--overwrite=OVERWRITE
Type: bool
Default: False
If True, reduced data directory and merged DEMS file
If True, the reduced package and the merged DEMS file
will be overwritten even if they exist.
--debug=DEBUG
Type: bool
Expand Down
4 changes: 2 additions & 2 deletions demerge/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
__all__ = ["data", "demerge", "merge", "reduce"]
__version__ = "2024.7.2"
__version__ = "2024.7.3"


# standard library
Expand Down Expand Up @@ -77,7 +77,7 @@ def demerge(
If not specified, a temporary directory will be used.
ddb: Path of DDB (DESHIMA database) file.
measure: Measure of the DEMS (either df/f or brightness).
overwrite: If True, reduced data directory and merged DEMS file
overwrite: If True, the reduced package and the merged DEMS file
will be overwritten even if they exist.
debug: If True, detailed logs for debugging will be printed.
**options: Other merge options for the merge command.
Expand Down
2 changes: 1 addition & 1 deletion demerge/merge/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
DATE_PARSER_ANTENNA = lambda s: dt.strptime(s, "%Y%m%d%H%M%S.%f")
DATE_PARSER_CABIN = lambda s: dt.strptime(s, "%Y/%m/%d %H:%M")
DATE_PARSER_MISTI = lambda s: dt.strptime(s, "%Y/%m/%d %H:%M:%S.%f")
DATE_PARSER_SKYCHOP = lambda s: dt.fromtimestamp(float(s))
DATE_PARSER_SKYCHOP = lambda s: dt.utcfromtimestamp(float(s))
DATE_PARSER_WEATHER = lambda s: dt.strptime(s, "%Y%m%d%H%M%S")
PACKAGE_DATA = Path(__file__).parents[1] / "data"

Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "demerge"
version = "2024.7.2"
version = "2024.7.3"
description = "DESHIMA merge code for observed datasets"
authors = [
"Tatsuya Takekoshi <tatsuya.takekoshi@gmail.com>",
Expand Down

0 comments on commit bebba98

Please sign in to comment.