Skip to content

Commit

Permalink
🔖 0.13.0 - arm64 fixes, update Marlu
Browse files Browse the repository at this point in the history
  • Loading branch information
d3v-null committed Aug 14, 2024
1 parent e13ae89 commit 6cdca57
Show file tree
Hide file tree
Showing 5 changed files with 35 additions and 22 deletions.
6 changes: 3 additions & 3 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "birli"
description = "A preprocessing pipeline for the Murchison Widefield Array"
version = "0.12.0"
version = "0.13.0"
readme = "README.md"
homepage = "https://github.com/MWATelescope/Birli"
repository = "https://github.com/MWATelescope/Birli"
Expand Down Expand Up @@ -43,7 +43,7 @@ indicatif = { version = "0.17.0", features = ["rayon"] }
itertools = "0.10.0"
lazy_static = "1.4.0"
log = "0.4.0"
marlu = "0.12.0"
marlu = "0.13.0"
regex = "1.4.0"
thiserror = "1.0.0"

Expand All @@ -64,7 +64,7 @@ csv = "1.1"
float-cmp = "0.9"
glob = "0.3"
lexical = "6.0"
marlu = { version = "0.12.0", features = ["approx"] }
marlu = { version = "0.13.0", features = ["approx"] }
ndarray = { version = "0.16.0", features = ["approx"] }
tempfile = "3.3"

Expand Down
9 changes: 9 additions & 0 deletions RELEASES.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
<!-- markdownlint-disable=MD025 -->

# Version 0.13.0 (2024-08-14)

- 🐛 fix issues compiling on arm64:
- update Marlu 0.13.0

# Version 0.12.0 (2024-06-27)

- 🐛 bug fixes:
- #152 default pfb gains should be cotter2014 for legacy correlator, not jake
- 🙏 quality of life:
Expand All @@ -9,18 +15,21 @@
- update default aoflagger version in makefile and dockerfile

# Version 0.11.0 (2024-06-19)

- ➕ dependencies:
- Marlu 0.11.0
- built ~0.7.3

# Version 0.10.0 (2023-08-11)

- 🙏 quality of life:
- uvfits are now written out with a second DATE and INTTIM
- ➕ dependencies:
- use Marlu 0.10.1
- use rust version 1.64

# Version 0.9.2 (2023-07-18)

- 🙏 quality of life:
- update modtime when writing ms

Expand Down
25 changes: 13 additions & 12 deletions src/flags.rs
Original file line number Diff line number Diff line change
Expand Up @@ -556,6 +556,7 @@ pub fn write_flags(
mod tests {
use super::write_flags;
use glob::glob;
use std::ffi::c_char;
use tempfile::tempdir;

use crate::{
Expand Down Expand Up @@ -677,18 +678,18 @@ mod tests {
);

let tests = [
(0, 0, 0, i8::from(false)),
(0, 0, 1, i8::from(false)),
(0, 1, 0, i8::from(false)),
(0, 1, 1, i8::from(false)),
(0, 2, 0, i8::from(false)),
(0, 2, 1, i8::from(false)),
(1, 0, 0, i8::from(false)),
(1, 0, 1, i8::from(false)),
(1, 1, 0, i8::from(false)),
(1, 1, 1, i8::from(true)),
(1, 2, 0, i8::from(false)),
(1, 2, 1, i8::from(false)),
(0, 0, 0, c_char::from(false)),
(0, 0, 1, c_char::from(false)),
(0, 1, 0, c_char::from(false)),
(0, 1, 1, c_char::from(false)),
(0, 2, 0, c_char::from(false)),
(0, 2, 1, c_char::from(false)),
(1, 0, 0, c_char::from(false)),
(1, 0, 1, c_char::from(false)),
(1, 1, 0, c_char::from(false)),
(1, 1, 1, c_char::from(true)),
(1, 2, 0, c_char::from(false)),
(1, 2, 1, c_char::from(false)),
];
for (timestep_idx, baseline_idx, fine_chan_idx, expected_flag) in tests {
let row_idx = timestep_idx * num_baselines + baseline_idx;
Expand Down
11 changes: 7 additions & 4 deletions src/io/mwaf.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,10 @@
//! one column. Each cell in the table contains a binary vector of flags for each fine channel in
//! the coarse channel.

use std::path::{Path, PathBuf};
use std::{
ffi::c_char,
path::{Path, PathBuf},
};

use fitsio::{tables::ColumnDataType, tables::ColumnDescription, FitsFile};
use indicatif::{MultiProgress, ProgressBar, ProgressDrawTarget, ProgressStyle};
Expand Down Expand Up @@ -441,7 +444,7 @@ impl FlagFileSet {

let mut status = 0;

let mut flag_cell = vec![0; flag_coarse_chan_view.len_of(Axis(1))];
let mut flag_cell: Vec<c_char> = vec![0; flag_coarse_chan_view.len_of(Axis(1))];
for flag_timestep_view in flag_coarse_chan_view.outer_iter() {
for (flag_baseline_view, baseline_flag_count) in flag_timestep_view
.axis_iter(Axis(1))
Expand All @@ -452,7 +455,7 @@ impl FlagFileSet {
.zip_eq(flag_baseline_view)
.zip_eq(channel_flag_counts.iter_mut())
.for_each(|((a, &b), count)| {
*a = i8::from(b);
*a = c_char::from(b);
if b {
*count += 1;
}
Expand Down Expand Up @@ -789,7 +792,7 @@ impl FlagFileSet {
}

#[cfg(test)]
pub(crate) fn read_flags(&self) -> Result<Array3<i8>, IOError> {
pub(crate) fn read_flags(&self) -> Result<Array3<c_char>, IOError> {
let gpubox = &self.gpuboxes[0];
let mut fptr = FitsFile::open(&gpubox.filename)?;
let hdu = fits_open_hdu!(&mut fptr, 0)?;
Expand Down

0 comments on commit 6cdca57

Please sign in to comment.