Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add inference output to sample write. #1256

Merged
merged 1 commit into from
May 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docker/Dockerfile.base
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
libvulkan-dev \
python3-numpy
WORKDIR /root
RUN git clone https://github.com/iqtlabs/gr-iqtlabs -b 1.0.95
RUN git clone https://github.com/iqtlabs/gr-iqtlabs -b 1.0.96
COPY --from=iqtlabs/gamutrf-vkfft:latest /root /root/gr-iqtlabs
WORKDIR /root/gr-iqtlabs/build
COPY --from=iqtlabs/gamutrf-sigmf:latest /usr/local /usr/local
Expand Down
8 changes: 8 additions & 0 deletions gamutrf/grscan.py
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@
self.last_db_block = self.fft_blocks[-1]
fft_dir = ""
self.samples_blocks = []
self.write_samples_block = None
if write_samples:
fft_dir = sample_dir
Path(sample_dir).mkdir(parents=True, exist_ok=True)
Expand Down Expand Up @@ -211,6 +212,8 @@
),
]
)
self.write_samples_block = self.samples_blocks[-1]

retune_fft = self.iqtlabs.retune_fft(
tag="rx_freq",
nfft=nfft,
Expand Down Expand Up @@ -314,6 +317,11 @@
power_inference=iq_power_inference,
)
self.inference_blocks.append(self.iq_inference_block)
if self.write_samples_block:
self.msg_connect(

Check warning on line 321 in gamutrf/grscan.py

View check run for this annotation

Codecov / codecov/patch

gamutrf/grscan.py#L320-L321

Added lines #L320 - L321 were not covered by tests
(self.iq_inference_block, "inference"),
(self.write_samples_block, "inference"),
)

# TODO: provide new block that receives JSON-over-PMT and outputs to MQTT/zmq.
retune_fft_output_block = None
Expand Down
Loading