Skip to content

Commit

Permalink
fix merge errors
Browse files Browse the repository at this point in the history
  • Loading branch information
jhazentia committed Apr 19, 2024
1 parent f133a52 commit 47163e4
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 3 deletions.
2 changes: 2 additions & 0 deletions README.md
Expand Up @@ -148,6 +148,7 @@ meta = SigMFFile(
SigMFFile.SAMPLE_RATE_KEY: 48000,
SigMFFile.AUTHOR_KEY: 'jane.doe@domain.org',
SigMFFile.DESCRIPTION_KEY: 'All zero complex float32 example file.',
SigMFFile.VERSION_KEY: "1.2.0"
}
)

Expand Down Expand Up @@ -187,6 +188,7 @@ meta_ci16 = SigMFFile(
SigMFFile.DATATYPE_KEY: 'ci16_le', # get_data_type_str() is only valid for numpy types
SigMFFile.SAMPLE_RATE_KEY: 48000,
SigMFFile.DESCRIPTION_KEY: 'All zero complex int16 file.',
SigMFFile.VERSION_KEY: "1.2.0"
}
)
meta_ci16.add_capture(0, metadata=meta.get_capture_info(0))
Expand Down
1 change: 1 addition & 0 deletions sigmf/sigmffile.py
Expand Up @@ -195,6 +195,7 @@ def __init__(self,
self.data_file = None
self.sample_count = 0
self._memmap = None
self.name = name
self.is_complex_data = False # numpy.iscomplexobj(self._memmap) is not adequate for fixed-point complex case

if metadata is None:
Expand Down
2 changes: 1 addition & 1 deletion tests/conftest.py
Expand Up @@ -72,7 +72,7 @@ def test_alternate_sigmffile(test_data_file_2):
@pytest.fixture
def test_alternate_sigmffile_2(test_data_file_3):
"""If pytest uses this signature, will return valid SigMF file."""
meta = SigMFFile()
meta = SigMFFile("test")
meta.set_global_field("core:datatype", "rf32_le")
meta.set_global_field("core:version", __specification__)
meta.add_annotation(start_index=0, length=len(TEST_FLOAT32_DATA_3))
Expand Down
4 changes: 4 additions & 0 deletions tests/test_archivereader.py
Expand Up @@ -6,12 +6,16 @@

"""Tests for SigMFArchiveReader"""

import os
import shutil
import tempfile
import unittest

import numpy as np

from sigmf import SigMFArchiveReader, SigMFFile, __specification__
from sigmf.archive import SIGMF_METADATA_EXT, SigMFArchive
from sigmf.sigmffile_collection import SigMFFileCollection


class TestArchiveReader(unittest.TestCase):
Expand Down
4 changes: 2 additions & 2 deletions tests/testdata.py
Expand Up @@ -32,7 +32,7 @@
SigMFFile.DATATYPE_KEY: 'rf32_le',
SigMFFile.HASH_KEY: 'a85018cf117a4704596c0f360dbc3fce2d0d561966d865b9b8a356634161bde6a528c5181837890a9f4d54243e2e8eaf7e19bd535e54e3e34aabf76793723d03',
SigMFFile.NUM_CHANNELS_KEY: 1,
SigMFFile.VERSION_KEY: '1.0.0'
SigMFFile.VERSION_KEY: __specification__,
}
}

Expand All @@ -45,7 +45,7 @@
SigMFFile.DATATYPE_KEY: 'rf32_le',
SigMFFile.HASH_KEY: '089753bd48a1724c485e822eaf4d510491e4e54faa83cc3e7b3f18a9f651813190862aa97c922278454c66f20a741050762e008cbe4f96f3bd0dcdb7d720179d',
SigMFFile.NUM_CHANNELS_KEY: 1,
SigMFFile.VERSION_KEY: '1.0.0'
SigMFFile.VERSION_KEY: __specification__,
}
}

Expand Down

0 comments on commit 47163e4

Please sign in to comment.