Skip to content

Commit

Permalink
Merge pull request #1021 from anarkiwi/log58
Browse files Browse the repository at this point in the history
add logging to custom_handler to debug batching.
  • Loading branch information
anarkiwi authored Dec 6, 2023
2 parents bcf55da + 37947c5 commit e48c8f5
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion docker/Dockerfile.base
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,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.57
RUN git clone https://github.com/iqtlabs/gr-iqtlabs -b 1.0.58
COPY --from=iqtlabs/gamutrf-vkfft:latest /root /root/gr-iqtlabs
WORKDIR /root/gr-iqtlabs/build
COPY --from=sigmf-builder /usr/local /usr/local
Expand Down
2 changes: 1 addition & 1 deletion docs/README-airt.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ install gr-iqtlabs
$ git clone https://github.com/google/flatbuffers -b v23.5.26
$ git clone https://github.com/nlohmann/json -b v3.11.2
$ git clone https://github.com/deepsig/libsigmf -b v1.0.2
$ git clone https://github.com/iqtlabs/gr-iqtlabs -b 1.0.57
$ git clone https://github.com/iqtlabs/gr-iqtlabs -b 1.0.58
$ mkdir -p flatbuffers/build && cd flatbuffers/build && cmake -DCMAKE_INSTALL_PREFIX=~/.conda/envs/$CONDA_DEFAULT_ENV .. && make -j $(nproc) && make install && cd ../..
$ mkdir -p json/build && cd json/build && cmake -DCMAKE_INSTALL_PREFIX=~/.conda/envs/$CONDA_DEFAULT_ENV .. && make -j $(nproc) && make install && cd ../..
$ mkdir -p libsigmf/build && cd libsigmf/build && cmake -DUSE_SYSTEM_JSON=ON -DUSE_SYSTEM_FLATBUFFERS=ON -DCMAKE_INSTALL_PREFIX=~/.conda/envs/$CONDA_DEFAULT_ENV -DCMAKE_CXX_FLAGS="-I $HOME/.conda/envs/$CONDA_DEFAULT_ENV/include" .. && make -j $(nproc) && make install && cd ../..
Expand Down
2 changes: 2 additions & 0 deletions torchserve/custom_handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ def _load_torchscript_model(self, model_pt_path):

def inference(self, data, *args, **kwargs):
kwargs.update(self.model_config)
print(f"inference got input tensor {data.shape}")
return super().inference(data, *args, **kwargs)

def postprocess(self, res):
Expand All @@ -81,4 +82,5 @@ def postprocess(self, res):
name = data.names[int(cls)]
result_dict[name].append({"conf": conf.item(), "xywh": xywh.tolist()})
output.append(result_dict)
print(f"postprocess returned results for {len(output)} inference(s)")
return output

0 comments on commit e48c8f5

Please sign in to comment.