Sionna: An Open-Source Library for Next-Generation Physical Layer Research

Overview

Sionna: An Open-Source Library for Next-Generation Physical Layer Research

Sionna™ is an open-source Python library for link-level simulations of digital communication systems built on top of the open-source software library TensorFlow for machine learning.

The official documentation can be found here.

Installation

Sionna requires Python and Tensorflow. In order to run the tutorial notebooks on your machine, you also need Jupyter. You can alternatively test them on Google Colab. Although not necessary, we recommend running Sionna in a Docker container.

Sionna requires TensorFlow 2.5 or higher and Python 3.6-3.9. We recommend Ubuntu 20.04.

We refer to the TensorFlow GPU support tutorial for GPU support and the required driver setup.

Installation using pip

We recommend to do this within a virtual environment, e.g., using conda. On macOS, you need to install tensorflow-macos first.

1.) Install the package

    pip install sionna

2.) Test the installation in Python

    python
    >>> import sionna
    >>> print(sionna.__version__)
    0.9.0

3.) Once Sionna is installed, you can run the Sionna "Hello, World!" example, have a look at the quick start guide, or at the tutorials.

The example notebooks can be opened and executed with Jupyter.

For a local installation, the JupyterLab Desktop application can be used which also includes the Python installation.

Docker-based installation

1.) Make sure that you have Docker installed on your system. On Ubuntu 20.04, you can run for example

    sudo apt install docker.io

Ensure that your user belongs to the docker group (see Docker post-installation)

    sudo usermod -aG docker $USER

Log out and re-login to load updated group memberships.

For GPU support on Linux, you need to install the NVIDIA Container Toolkit.

2.) Build the Sionna Docker image. From within the Sionna directory, run

    make docker

3.) Run the Docker image with GPU support

    make run-docker gpus=all

or without GPU:

    make run-docker

This will immediately launch a Docker image with Sionna installed, running Jupyter on port 8888.

4.) Browse through the example notebooks by connecting to http://127.0.0.1:8888 in your browser.

Installation from source

We recommend to do this within a virtual environment, e.g., using conda.

1.) Clone this repository and execute from within its root folder

    make install

2.) Test the installation in Python

    >>> import sionna
    >>> print(sionna.__version__)
    0.8.0

License and Citation

Sionna is Apache-2.0 licensed, as found in the LICENSE file.

If you use this software, please cite it as:

@article{sionna,
    title = {Sionna: An Open-Source Library for Next-Generation Physical Layer Research},
    author = {Hoydis, Jakob and Cammerer, Sebastian and {Ait Aoudia}, Fayçal and Vem, Avinash and Binder, Nikolaus and Marcus, Guillermo and Keller, Alexander},
    year = {2022},
    month = {Mar.},
    journal = {arXiv preprint},
    online = {https://arxiv.org/abs/2203.11854}
}
Comments
  • Part 4: Toward Learned Receivers Bug TensorShape to a Tensor: (None, None)

    Part 4: Toward Learned Receivers Bug TensorShape to a Tensor: (None, None)

    When trying the Part 4: Toward Learned Receivers example at the step Training the Neural Receiver I get an error about TensorShape to a Tensor: (None, None) while i did not alter the example in any way. why is this? The full error is bellow:

    Traceback (most recent call last): File "/cm/local/apps/slurm/var/spool/job6555120/slurm_script", line 308, in loss = model(BATCH_SIZE, ebno_db) File "/home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/eager/def_function.py", line 885, in call result = self._call(*args, **kwds) File "/home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/eager/def_function.py", line 933, in _call self._initialize(args, kwds, add_initializers_to=initializers) File "/home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/eager/def_function.py", line 760, in _initialize *args, **kwds)) File "/home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/eager/function.py", line 3066, in _get_concrete_function_internal_garbage_collected graph_function, _ = self._maybe_define_function(args, kwargs) File "/home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/eager/function.py", line 3463, in _maybe_define_function graph_function = self._create_graph_function(args, kwargs) File "/home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/eager/function.py", line 3308, in _create_graph_function capture_by_value=self._capture_by_value), File "/home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/framework/func_graph.py", line 1007, in func_graph_from_py_func func_outputs = python_func(*func_args, **func_kwargs) File "/home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/eager/def_function.py", line 668, in wrapped_fn out = weak_wrapped_fn().wrapped(*args, **kwds) File "/home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/eager/function.py", line 3990, in bound_method_wrapper return wrapped_fn(*args, **kwargs) File "/home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/framework/func_graph.py", line 994, in wrapper raise e.ag_error_metadata.to_exception(e) ValueError: in user code:

    /cm/local/apps/slurm/var/spool/job6555120/slurm_script:280 __call__  *
        llr = self.rg_demapper(llr) # Extract data-carrying resource elements. The other LLrs are discarded
    /home/tue/20184223/.local/lib/python3.6/site-packages/sionna/ofdm/resource_grid.py:470 call  *
        y = flatten_dims(y, 2, 2)
    /home/tue/20184223/.local/lib/python3.6/site-packages/sionna/utils/tensors.py:76 flatten_dims  *
        flat_dim = tf.reduce_prod(tensor.shape[axis:axis+num_dims])
    /home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/util/dispatch.py:206 wrapper  **
        return target(*args, **kwargs)
    /home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/ops/math_ops.py:2744 reduce_prod
        input_tensor, _ReductionDims(input_tensor, axis), keepdims,
    /home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/ops/math_ops.py:2094 _ReductionDims
        return range(0, array_ops.rank(x))
    /home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/util/dispatch.py:206 wrapper
        return target(*args, **kwargs)
    /home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/ops/array_ops.py:839 rank
        return rank_internal(input, name, optimize=True)
    /home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/ops/array_ops.py:859 rank_internal
        input = ops.convert_to_tensor(input)
    /home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/profiler/trace.py:163 wrapped
        return func(*args, **kwargs)
    /home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/framework/ops.py:1566 convert_to_tensor
        ret = conversion_func(value, dtype=dtype, name=name, as_ref=as_ref)
    /home/tue/20184223/.local/lib/python3.6/site-packages/tensorflow/python/framework/constant_op.py:363 _tensor_shape_tensor_conversion_function
        "Cannot convert a partially known TensorShape to a Tensor: %s" % s)
    
    ValueError: Cannot convert a partially known TensorShape to a Tensor: (None, None)
    
    opened by BramvBk 7
  • 8PSK constellation diagram

    8PSK constellation diagram

    Hi!

    I wanted to compare different Bit Error Rates for different modulations (QPSK, 8PSK and 16QAM) for the uncoded and encoded case (LDPC). The system is is the same, just the modulation differs...

    output1 output2

    I'm not sure if the 8PSK plot is correct. Especially in the encoded case, as the BER doesnt seem to improve with the encoder. For the QAM and 16QAM the encoded plot looks better, as an improvement is visible, in contrast to the uncoded case. Where I think the mistake may be, is during the set up of the constellation diagram for the mapper and demapper:

    8PSK: const8PSK

    NUM_BITS_PER_SYMBOL = 3
    BLOCK_LENGTH = 3**8
    n=12*3
    
    real = 1 * np.cos(np.pi/4)
    imag = 1 * np.sin(np.pi/4)
    CONST_SHAPE = np.array([-1, 1, 1j, -1j, complex(real, imag), complex(real, -imag), complex(-real, imag), complex(-real, -imag)]) # set the shape of the constellation diagram
    constellation = sn.mapping.Constellation("custom", NUM_BITS_PER_SYMBOL, CONST_SHAPE, normalize=True, center=True)
    constellation.show()
    

    16QAM: const16qam

    NUM_BITS_PER_SYMBOL = 4
    BLOCK_LENGTH = 2**8
    n=2**8
    
    constellation = sn.mapping.Constellation("qam", NUM_BITS_PER_SYMBOL, normalize=True, center=True)
    constellation.show();
    

    QPSK: constqpsk

    NUM_BITS_PER_SYMBOL = 2
    BLOCK_LENGTH = 2**8
    n=2**8
    
    constellation = sn.mapping.Constellation("qam", NUM_BITS_PER_SYMBOL, normalize=True, center=True)
    constellation.show();
    

    Any help or ideas would be greatly appriciated, thanks!

    opened by Koltice 6
  • PolarSCLDecoder has last bit wrong

    PolarSCLDecoder has last bit wrong

    I have a test case where I compare it with results from matlab:

    A = 32
    P = 24
    K = A+P
    N = 512 # calculated according to Section 5.3.1 of 3GPP TS 38.212
    decIn = np.array([98.0994,   100.2936,  -100.1615,  -111.2452,  -101.7249,  -101.5950,    78.5901,   -77.7265,   -76.4686,   -81.3223,  -115.8069,    89.6047,    85.9367,   104.1048,   -98.2053,  -106.7203,    83.1207,    88.2861,    83.8204,  -109.2175,  -124.4919,    94.6728,    91.5959,   -89.5352,  -101.8143,  -123.6915,  -103.1579,  -108.0879,   100.9417,   -95.5231,   122.5312,    99.6845,   -78.9441,   115.9421,    65.5815,    90.9532,   -88.9573,   -85.7132,   -83.5216,   -78.7969,   -54.1358,    75.8672,    84.9239,   -89.5731,   -92.8101,   -76.0732,    72.9594,   -74.3997,    93.8353,   -80.0016,    83.2706,  -104.8245,    75.5381,   -89.3799,    86.4390,    84.6055,    43.8157,  -100.4702,   -79.0332,   -89.0215,   109.9606,   -99.6110,   111.9779,  -101.8772,   -68.2989,    93.4047,    95.1260,    79.8283,    80.2065,   -89.3344,    68.9841,   -77.7767,    95.8681,   -79.4709,    62.2583,   -63.4266,   -91.1614,    81.0331,   -83.1753,   -95.7477,    79.3811,   -78.2227,   109.3239,   -70.7376,   -90.1096,   -93.8385,   -83.5296,    79.8664,  -107.2777,    86.7808,   -83.8104,   -89.5405,    83.9844,    88.8928,  -114.4005,   -81.6010,    68.2572,   100.1189,   -94.9682,  -106.6306,    94.3960,   -75.7935,   -80.0656,   -80.4422,    80.0088,    78.5461,  -101.9442,   101.2641,    79.4489,   -82.3328,    85.9272,   -93.2934,    96.1777,    88.5216,    84.3977,   -82.6021,    84.0117,    95.0405,   -86.1691,   -74.1916,   108.7456,    86.4657,   -75.5564,   -99.4773,    74.5251,    98.5329,   -83.2432,    70.5688,   -68.4671,   -79.3403,   -62.6724,   -60.8476,    67.8379,    91.1800,    87.8499,  -101.2957,   -69.6481,   -74.5603,    70.1766,   -99.2101,   101.3056,    57.1986,    87.5917,    84.1423,   -66.9824,   -62.7680,    60.1339,   -78.9674,    65.3749,   -64.6940,    50.0190,   -89.6008,   -59.3167,   -63.1129,    61.5982,    48.8499,    65.2957,   -44.2573,   -67.7464,   -87.8192,    73.3080,   -55.5333,    61.1872,    83.1372,    72.6622,    56.7458,   -90.9942,   -99.5641,   -62.1492,    75.1305,   -67.2248,    82.1078,   -71.9184,   -96.0142,   -82.4769,    63.0060,   -78.2155,    88.4656,    78.1025,   -62.1181,   -66.5374,    74.3818,    84.9285,    65.4854,    60.3368,   -59.9013,    62.8409,    45.3090,    58.8132,   -90.1745,   -80.5019,    76.9129,    53.0226,   -60.5902,    68.6878,    71.6496,   -79.5789,    68.2251,    69.2261,   -57.2262,    67.4926,   -56.8821,   -78.9174,    54.9742,   -77.1147,    72.3281,    45.8284,    74.1518,   -96.2469,    74.1641,    71.7959,   -84.9770,    75.2968,    43.3046,   -75.7478,    79.3113,   -67.3357,    83.5540,    88.1043,    92.9397,    60.5756,    96.0108,    68.6091,    56.8510,   -81.4292,   -84.7288,   -61.2944,   -77.7179,   -74.2870,    73.8435,   -68.7351,   -50.0336,    55.0304,    84.1329,    68.3470,   -42.6786,    51.2943,   -66.9083,   -66.1926,    79.1121,   -59.2044,   -69.6405,    89.3530,   -68.6773,   -78.4004,   -57.7046,   -56.9396,   -56.8815,    84.8120,    85.3458,    72.9297,    90.6085,   110.8704,    81.9232,    78.7975,   -75.6312,   -76.4349,   -65.0490,    66.5703,    77.3265,    70.3819,    58.6750,   -61.8244,    94.9379,    68.1455,    80.8718,    71.4065,   -89.3790,   -42.6856,   -64.9363,    76.2369,    69.3416,   -64.3863,   -64.0232,   -58.3138,    79.5344,    67.9879,   -79.1206,   -79.1714,    60.2715,    72.0637,    87.6743,    87.1759,    81.4093,   -74.1212,   100.5560,   -82.5535,   -56.7645,    90.7906,  -100.7988,   -64.6227,   -98.9736,    89.3586,    78.5604,    99.6034,    55.0377,    83.2926,   -72.7276,   -98.3970,    71.7933,    61.7939,    67.9014,   -69.5731,    73.2906,   -70.8013,    63.1397,   -52.9220,    80.8111,   -76.1652,    76.7023,   -66.0006,   -52.8898,   -67.6308,    85.2930,    78.6230,    75.2349,   -75.5770,    61.5977,   -82.0592,    56.5244,    73.6083,   -91.9549,   -48.5210,   -68.8685,   -87.2434,    55.9644,   -90.2183,    76.1801,   -85.3346,    66.5699,   -93.3345,    46.6941,    74.9255,   -85.1393,    65.0381,    59.5640,   -65.9826,    84.1422,   -68.0985,    74.0803,    66.0246,    83.8283,    78.7515,   -80.7086,    52.4481,   -66.9362,    56.3773,    65.2047,   -60.8237,   -76.4423,    79.9544,    76.8582,   -76.3870,   -74.6423,    50.1182,    43.6267,   -69.2405,    65.5949,    78.9524,    64.1765,   -55.5729,   -64.7979,    61.4107,   -74.2137,   -74.3217,    62.0394,   -74.1537,    69.4664,   -96.5727,   -98.9427,   -77.9188,    81.6283,   -92.4196,   -81.5016,   116.7946,   111.1792,  -104.2775,  -102.8753,   105.5464,    73.3699,  -121.8863,   -83.9218,    99.9105,   -76.7338,    71.2199,    84.3709,   123.7199,    78.3144,  -110.0666,  -102.4246,   -94.3307,    82.9367,    96.7602,    97.7912,   -85.7501,    88.8595,   -71.4018,   -73.5545,   -58.8523,  -103.0843,    97.3005,    78.5062,  -109.6570,    85.2691,   -91.4737,    87.4685,   -87.5806,   106.0338,    76.4113,   112.0384,   -78.9545,   -67.7884,   -70.9985,    84.6570,    98.7297,    91.5841,   -83.0778,   108.2129,   -94.8490,   -87.3756,  -111.9341,   -86.7001,    95.5885,   115.4110,    72.8125,  -106.4446,    80.6854,   -90.9581,    87.6573,    68.6028,   103.3637,   -92.1900,    73.5025,   -53.7392,   -64.1919,   106.1772,    79.7842,   -69.1110,   -79.4048,   -98.8703,   -57.1228,    62.4514,   -93.6077,   -45.7700,   -68.4287,    71.8675,    66.7427,   -63.6768,   -74.7351,    68.3605,   -64.5109,   -86.4599,    92.2079,   -62.3135,   -47.5140,    74.8112,   -55.6607,    72.2295,    98.2756,   -54.4462,   104.4787,   -76.8929,   -84.0509,   -87.5470,    88.1545,   -38.5373,   -73.9172,    86.9245,   -65.0378,   -62.6790,    76.2379,   -54.8815,    70.4215,   -64.9437,   -64.9268,   -78.1091,   -52.9684,   -53.5112,   -67.4531,   -47.4951,    54.0182,    62.7692,    47.2771,    64.6934,    62.8590,   -63.9107,    52.5923,    69.3743,   -64.8862,   -76.7852,   -60.9050,    51.3035,   -61.0244,    75.3462,    66.0729,   -50.1459,    61.4202,    80.4490,   -65.3638,    65.9481,    66.2290,    68.6534,    48.4402,    76.8827,   -88.6572,  -102.7420,   -94.8729,  -128.7776,  -122.5039,  -111.4672,  -105.0354,   107.5132])
    from sionna.fec.polar import PolarEncoder, Polar5GEncoder, PolarSCLDecoder, Polar5GDecoder, PolarSCDecoder
    from sionna.fec.polar.utils import generate_5g_ranking
    
    # decode
    frozen_pos, info_pos = generate_5g_ranking(K, N)
    decoder = PolarSCLDecoder(frozen_pos, N, list_size=8, crc_degree='CRC24C', cpu_only=True, use_fast_scl=False)
    decoded = np.array(decoder(np.expand_dims(decIn, 0))[0], 'int')
    
    def interleave(c):
    # 38.212 Table 5.3.1.1-1
        p_IL_max_table = [0, 2, 4, 7, 9, 14, 19, 20, 24, 25, 26, 28, 31, 34, 42, 45, 49, 50, 51, 53, 54, 56, 58, 59, 61, 62, 65, 66, 67, 69, 70, 71, 72, 76, 77, 81, 82, 83, 87, 88, 89, 91, 93, 95, 98, 101, 104, 106, 108, 110, 111, 113, 115, 118, 119, 120, 122, 123, 126, 127, 129, 132, 134, 138, 139, 140, 1, 3, 5, 8, 10, 15, 21, 27, 29, 32, 35, 43, 46, 52, 55, 57, 60, 63, 68, 73, 78, 84, 90, 92, 94, 96, 99, 102, 105, 107, 109, 112, 114, 116, 121, 124, 128, 130, 133, 135, 141, 6, 11, 16, 22, 30, 33, 36, 44, 47, 64, 74, 79, 85, 97, 100, 103, 117, 125, 131, 136, 142, 12, 17, 23, 37, 48, 75, 80, 86, 137, 143, 13, 18, 38, 144, 39, 145, 40, 146, 41, 147, 148, 149, 150, 151, 152, 153, 154, 155, 156, 157, 158, 159, 160, 161, 162, 163]
        k = 0
        K_IL_max = 164
        p = np.empty(c.shape[0], 'int')
        for p_IL_max in p_IL_max_table:
            if p_IL_max >= (K_IL_max - K):
                p[k] = p_IL_max - (K_IL_max - K)
                k += 1
        return p
    
    # deinterleave
    p_IL = interleave(decoded)
    decoded2 = np.empty(decoded.shape, 'int')
    np.put(decoded2, p_IL, decoded)
    

    the result in python is [0, 1, 0, 0, 1, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 0, 1, 1, 1, 0, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1]

    the result in matlab when using nrPolarDecode() is [0, 1, 0, 0, 1, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 0, 1, 1, 1, 0, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0]

    which is the same as in python, except the last bit. When I put the matlab result into nrCRCDecode() it says checksum ok, with the python result it says checksum wrong.

    input = [0, 1, 0, 0, 1, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 0, 1, 1, 1, 0, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1]';
    [data, cs] = nrCRCDecode(input,'24C')
    

    gives cs = 1, which means error

    input = [0, 1, 0, 0, 1, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 0, 1, 1, 1, 0, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0]';
    [data, cs] = nrCRCDecode(input,'24C')
    

    gives cs = 0, which means ok

    opened by catkira 5
  • Passing Constellation to MaximumLikelihoodDetector doesn't work

    Passing Constellation to MaximumLikelihoodDetector doesn't work

    Describe the bug Passing a Constellation object as the constellation parameter to MaximumLikelihoodDetector gives a TypeError

    To Reproduce

    See this example

    import sionna
    from sionna.mapping import Constellation
    from sionna.mimo import MaximumLikelihoodDetector
    
    print(sionna.__version__)
    
    mld1 = MaximumLikelihoodDetector('bit', 'app', 6, constellation_type='qam', num_bits_per_symbol=2)
    mld2 = MaximumLikelihoodDetector('bit', 'app', 6, constellation=Constellation(constellation_type='qam', num_bits_per_symbol=2))
    

    which produces this output:

    0.10.0
    ---------------------------------------------------------------------------
    TypeError                                 Traceback (most recent call last)
    Input In [6], in <cell line: 8>()
          5 print(sionna.__version__)
          7 mld1 = MaximumLikelihoodDetector('bit', 'app', 6, constellation_type='qam', num_bits_per_symbol=2)
    ----> 8 mld2 = MaximumLikelihoodDetector('bit', 'app', 6, constellation=Constellation(constellation_type='qam', num_bits_per_symbol=2))
    
    File ~/anaconda3/envs/noma/lib/python3.10/site-packages/sionna/mimo/detection.py:237, in MaximumLikelihoodDetector.__init__(self, output, demapping_method, k, constellation_type, num_bits_per_symbol, constellation, hard_out, dtype, **kwargs)
        234 self._c = tf.cast(c, tf.int32)
        236 if output == 'bit':
    --> 237     self._logits2llr = SymbolLogits2LLRs(
        238                             method=demapping_method,
        239                             num_bits_per_symbol=num_bits_per_symbol,
        240                             hard_out=hard_out,
        241                             dtype=dtype.real_dtype,
        242                             **kwargs)
    
    File ~/anaconda3/envs/noma/lib/python3.10/site-packages/sionna/mapping.py:641, in SymbolLogits2LLRsWithPrior.__init__(self, method, num_bits_per_symbol, hard_out, dtype, **kwargs)
        639 self._hard_out = hard_out
        640 self._num_bits_per_symbol = num_bits_per_symbol
    --> 641 num_points = int(2**num_bits_per_symbol)
        643 # Array composed of binary representations of all symbols indices
        644 a = np.zeros([num_points, num_bits_per_symbol])
    
    TypeError: unsupported operand type(s) for ** or pow(): 'int' and 'NoneType'
    

    Expected behavior No TypeError

    To Fix: Replace line 239 of detection.py with

    num_bits_per_symbol=self._constellation.num_bits_per_symbol,
    
    opened by daniel-sch 5
  • `PanelArray.show()` displays same antenna orientation for different polarization types.

    `PanelArray.show()` displays same antenna orientation for different polarization types.

    Describe the bug While plotting the panel array geometry using the PanelArray.show() function, the same antenna array is shown for both polarization type 'VH' and 'cross'. Ideally, the antenna orientation for cross polarization should be rotated by 45 degree w.r.t. polarization type 'VH.

    To Reproduce

    from sionna.channel.tr38901 import PanelArray
    
    array = PanelArray(num_rows_per_panel = 4,
                       num_cols_per_panel = 4,
                       polarization = 'dual',
                       polarization_type = 'cross',
                       antenna_pattern = '38.901',
                       carrier_frequency = 3.5e9)
    
    array.show()
    

    Expected behavior The plot when polarization type is set to 'cross' should be as below: image

    Proposed solution The markers for antenna, when plotting figure with polarization type 'cross', should be rotated by 45 degrees. Please find the modified PanelArray.show() function:

    def show(self):
        """Show the panel array geometry"""
        marker_vert = MarkerStyle("|")
        marker_horz = MarkerStyle("_")
        if self._polarization == 'dual' and self._polarization_type == 'cross':
            marker_vert = MarkerStyle("|")
            marker_vert._transform.rotate_deg(-45)
            marker_horz = MarkerStyle("_")
            marker_horz._transform.rotate_deg(-45)
    
        fig = plt.figure()
        pos_pol1 = self._ant_pos_pol1
        plt.plot(pos_pol1[:,1], pos_pol1[:,2], marker = marker_vert,
            markeredgecolor='red', markersize="20", linestyle="None",
            markeredgewidth="2")
        for i, p in enumerate(pos_pol1):
            fig.axes[0].annotate(self._ant_ind_pol1[i].numpy()+1, (p[1], p[2]))
        if self._polarization == 'dual':
            pos_pol2 = self._ant_pos_pol2
            plt.plot(pos_pol2[:,1], pos_pol2[:,2], marker = marker_horz,
                markeredgecolor='black', markersize="20", linestyle="None",
                markeredgewidth="1")
        plt.xlabel("y (m)")
        plt.ylabel("z (m)")
        plt.title("Panel Array")
        plt.legend(["Polarization 1", "Polarization 2"], loc="upper right")
    
    opened by echacko 5
  • OFDMModulator() returns a time-domain OFDM signal with `size = None` (in training)

    OFDMModulator() returns a time-domain OFDM signal with `size = None` (in training)

    Describe the bug The class OFDMModulator() returns a time-domain OFDM signal with size = None while Training the Keras model. (only while training the model)

    To Reproduce Please find a gist link : "https://gist.github.com/kassankar/70d62384d05b00fa8b9486ed862a4784" to reproduce the error.

    The bug occurred while running block number 7 due to OFDMModulator() in block number 6.

    Expected behavior Based on the OFDMModulator description, the function should return an output size = num_ofdm_symbols*(fft_size+cyclic_prefix_length)

    Screenshots

    image

    Additional context The problem is directly connected to the function flatten_last_dims() used in the OFDMModulator() class. More precisely, in the last two lines new_shape = tf.concat([shape[:-num_dims], [-1]], 0), return tf.reshape(tensor, new_shape). I think the problem is occuring due to the use of [-1] in the tf.reshape() function. In the training the batch_size is equal to None, and based on the description of the tf.reshape() function with an axis shape = [-1], the dimension is computed so that the total size remains constant. However, due to batch_size = None, the tf.reshape() return another 'None' dimension for the last output.

    Note: tf.reshape() with [-1] is also used in OFDMDemodulator(), in new_shape = tf.concat([tf.shape(inputs)[:-1], [-1], [self.fft_size + self.cyclic_prefix_length]], 0)

    opened by kassankar 5
  • Simulating a single transmitter transmitting to multiple receiver

    Simulating a single transmitter transmitting to multiple receiver

    Hi! First of all thank you for this software. I was trying to build a simulation where 2 MIMO BS receive data from a single-antenna receiver. Accordingly, I set the number of tx_streams to be equal to 1; however, the StreamManagement object returns that the _detection_desired_ind is empty, because the num_streams_per_rx is 0. Therefore, the stream results undesired to both receiver and the LMMSEEqualizer tries to output an empty x_hat estimated from an empty h_dt_desired tensor. This generated an error in line 241 of ofdm/equalizer.py, when x_hat is reshaped.

    Is this a bug, or is it intended? If the latter, did I make some mistake in the set up? In the follows, I paste the code for the setup of the Stream Management, while is it attach the whole script (only 86 lines of code). Thank you!

    self._num_ut = 1
    self._num_bs = 2
    self._num_ut_ant = 1
    self._num_bs_ant = 64
    self._num_streams_per_tx = self._num_ut_ant
    self._perfect_csi = perfect_csi
    
    # Setup Stream Management
    self._rx_tx_association = np.zeros([self._num_bs, self._num_ut])
    self._rx_tx_association[:, 0] = 1
    self._stream_management = sn.mimo.StreamManagement(self._rx_tx_association, self._num_streams_per_tx)
    

    rayleigh_experiment.zip

    Screenshots Added the screenshot of the error: Screenshot from 2022-11-25 16-06-33

    System:

    • OS: Ubuntu 20.04 and Linux Mint (last)
    • NVIDIA Driver version: 510.85.02
    • CUDA version: 11.6
    • Python version: 3.7 and 3.8
    • TensorFlow version: 2.6.2 Tested also in Google collab, same issue there.
    opened by lostinafro 4
  • Problem with PanelArray() class show() function

    Problem with PanelArray() class show() function

    Problem: In the beginner tutorial part 3: advanced link level simulations, when executing the command "UT_ARRAY.show()" the following error occurs: "Type Error: float() argument must be a string or a number, not 'MarkStyle'".

    Possible solution: The error happens because in the show() function of the PanelArray() class, marker_vert and marker_horz are objects and the argument 'marker' must be a string. The possible solution is to use the get_marker() function which returns a string. This way: marker = marker_vert.get_marker() marker = marker_horz.get_marker()

    Best regards, Pedro

    opened by pedrohenriiique 4
  • Problem running the Example Notebook - 'Discover Sionna'

    Problem running the Example Notebook - 'Discover Sionna'

    I am in the process of setting up the environment on Mac OS and explore Sionna using the examples provided. The Discover Sionna notebook throws-up error half-way into the execution. I am attaching the complete pdf version of the executed notebook. Further, I have added code in the notebook to print the version of OS, python, TensorFlow etc installed in my environment to help debugging.

    Please help me setup the environment correctly. Discover_Sionna-3.pdf

    opened by fayazur-mohammad 4
  • `ResourceGridDemapper` layer contains some bugs.

    `ResourceGridDemapper` layer contains some bugs.

    Describe the bug The layer ResourceGridDemapper does not work properly.

    To Reproduce Please, find below a minimal code to reproduce the error:

    import tensorflow as tf
    from tensorflow.keras import Model
    from sionna.ofdm import ResourceGrid,ResourceGridDemapper
    from sionna.mimo import StreamManagement
    from sionna.utils import QAMSource
    import numpy as np
    
    class E2ESystem(Model):
        def __init__(self):
            super().__init__()
            self.cp_length = 0
            self.fft_size = 72
            self.num_ofdm_symbols = 14
            self.num_streams_per_tx = 1
            self.subcarrier_spacing = 15e3
            self.stream_manager = StreamManagement(np.array([[1]]),1)
            self.rg = ResourceGrid(num_ofdm_symbols = self.num_ofdm_symbols,
                      fft_size = self.fft_size,
                      subcarrier_spacing = self.subcarrier_spacing,
                      num_tx = 1,
                      num_streams_per_tx = self.num_streams_per_tx)
            self.qam = QAMSource(4)
            self.rg_demap  = ResourceGridDemapper(self.rg,self.stream_manager)
    
        
        @tf.function
        def call(self, batch_size):
            x_rg = self.qam([batch_size, 1, 1, self.num_ofdm_symbols, self.fft_size])
            print(x_rg.shape)
            x_rg_dem = self.rg_demap(x_rg)
            return x_rg_dem
    
    e2e = E2ESystem()
    e2e(128)
    
    

    Expected behavior The ResourceGridDemapper layer should return the data mapped from the qam layer.

    Proposed solution In the ResourceGridDemapper layer replace : 1. if tf.rank(y)==5: --> if len(y.shape)==5: 2. if tf.shape(y)[-1]==1: --> if y.shape[-1]==1: Please, find below the new version of the layer:

    class _ResourceGridDemapper(Layer):
        # pylint: disable=line-too-long
        r"""ResourceGridDemapper(resource_grid, stream_management, dtype=tf.complex64, **kwargs)
    
        Extracts data-carrying resource elements from a resource grid.
    
        This layer takes as input an OFDM :class:`~sionna.ofdm.ResourceGrid` and
        extracts the data-carrying resource elements. In other words, it implements
        the reverse operation of :class:`~sionna.ofdm.ResourceGridMapper`.
    
        Parameters
        ----------
        resource_grid : ResourceGrid
            An instance of :class:`~sionna.ofdm.ResourceGrid`.
    
        stream_management : StreamManagement
            An instance of :class:`~sionna.mimo.StreamManagement`.
    
        dtype : tf.Dtype
            Datatype for internal calculations and the output dtype.
            Defaults to `tf.complex64`.
    
        Input
        -----
        : [batch_size, num_rx, num_streams_per_rx, num_ofdm_symbols, fft_size, data_dim]
            The full OFDM resource grid in the frequency domain.
            The last dimension `data_dim` is optional. If `data_dim`
            is used, it refers to the dimensionality of the data that should be
            demapped to individual streams. An example would be LLRs.
    
        Output
        ------
        : [batch_size, num_rx, num_streams_per_rx, num_data_symbols, data_dim]
            The data that were mapped into the resource grid.
            The last dimension `data_dim` is only returned if it was used for the
            input.
        """
        def __init__(self,
                     resource_grid,
                     stream_management,
                     dtype=tf.complex64,
                     **kwargs):
            super().__init__(dtype=dtype, **kwargs)
            self._stream_management = stream_management
            self._resource_grid = resource_grid
    
            # Precompute indices to extract data symbols
            mask = resource_grid.pilot_pattern.mask
            num_data_symbols = resource_grid.pilot_pattern.num_data_symbols
            data_ind = tf.argsort(flatten_last_dims(mask), direction="ASCENDING")
            self._data_ind = data_ind[...,:num_data_symbols]
    
        def call(self, y): # pylint: disable=arguments-renamed
    
            # y has shape
            # [batch_size, num_rx, num_streams_per_rx, num_ofdm_symbols,...
            # ..., fft_size, data_dim]
    
            # If data_dim is not provided, add a dummy dimension
            if len(y.shape)==5:
                y = tf.expand_dims(y, -1)
    
            # Remove nulled subcarriers from y (guards, dc). New shape:
            # [batch_size, num_rx, num_rx_ant, ...
            #  ..., num_ofdm_symbols, num_effective_subcarriers, data dim]
            y = tf.gather(y, self._resource_grid.effective_subcarrier_ind, axis=-2)
    
            # Transpose tensor to shape
            # [num_rx, num_streams_per_rx, num_ofdm_symbols,...
            #  ..., num_effective_subcarriers, data_dim, batch_size]
            y = tf.transpose(y, [1, 2, 3, 4, 5, 0])
    
            # Merge num_rx amd num_streams_per_rx
            # [num_rx * num_streams_per_rx, num_ofdm_symbols,...
            #  ...,num_effective_subcarriers, data_dim, batch_size]
            y = flatten_dims(y, 2, 0)
    
            # Put first dimension into the right ordering
            stream_ind = self._stream_management.stream_ind
            y = tf.gather(y, stream_ind, axis=0)
    
            # Reshape first dimensions to [num_tx, num_streams] so that
            # we can compared to the way the streams were created.
            # [num_tx, num_streams, num_ofdm_symbols, num_effective_subcarriers,...
            #  ..., data_dim, batch_size]
            num_streams = self._stream_management.num_streams_per_tx
            num_tx = self._stream_management.num_tx
            y = split_dim(y, [num_tx, num_streams], 0)
    
            # Flatten resource grid dimensions
            # [num_tx, num_streams, num_ofdm_symbols*num_effective_subcarriers,...
            #  ..., data_dim, batch_size]
            y = flatten_dims(y, 2, 2)
    
            # Gather data symbols
            # [num_tx, num_streams, num_data_symbols, data_dim, batch_size]
            y = tf.gather(y, self._data_ind, batch_dims=2, axis=2)
    
            # Put batch_dim first
            # [batch_size, num_tx, num_streams, num_data_symbols]
            y = tf.transpose(y, [4, 0, 1, 2, 3])
    
            # Squeeze data_dim
            if y.shape[-1]==1:
                y = tf.squeeze(y, -1)
    
            return y
    
    opened by kassankar 4
  • _init_rate_match(k, n) gives wrong CRC degree

    _init_rate_match(k, n) gives wrong CRC degree

    I want to decode the PBCH. In matlab I can do it like this

        iBIL = false;
        iIL = true;
        crcLen = 24;
        nMax = 9;
        A = 32;
        P = 24;
        K = A+P;
        N = 512;
        decIn = nrRateRecoverPolar(pbchBits_csi,K,N,iBIL);
        decBits = nrPolarDecode(decIn,K,E,polarListLength,nMax,iIL,crcLen);
    

    However when I try it with sionna like this

        from sionna.fec.polar import PolarEncoder, Polar5GEncoder, PolarSCLDecoder, Polar5GDecoder, PolarSCDecoder
        enc = Polar5GEncoder(k=K, n=864)
        dec = Polar5GDecoder(enc, dec_type="SCL", list_size=8)
        dec(np.expand_dims(pbchBits_csi, 0))
    

    I get a wrong (different than matlab) result. I know the matlab result is correct, because the CRC gives 0. I found something suspicious with enc._init_rate_match(k, n), when I call it with k=54 and n=512 (or n=864) it gives CRC order 11, but it should be 24 (24C CRC polynomial). Is this a bug?

    opened by catkira 3
  • Add optional deinterleaving to PolarSCLDecoder so that 5G downstream signals can be decoded

    Add optional deinterleaving to PolarSCLDecoder so that 5G downstream signals can be decoded

    Description

    Until now it is not possible to decode 5G downstream signals, because deinterleaving according to TS 38.212 Table 5.3.1.1 (I_IL) is not implemented. This PR implements:

    • optional deinterleaving (I_IL) in PolarSCLDecoder and PolarEncoder and Polar5GEncoder
    • optional channel interleaving (B_IL) in Polar5GDecoder and Polar5GEncoder
    • optional specification of CRC polynomial to Polar5GEncoder
    • make payload incl crc available as attribute in Polar5GDecoder

    This PR is still WIP, but I already open it for discussion. All changes preserve the old API and should not affect existing use cases.

    Decoding of 5G PBCH signal with deinterleaving works (the checksum inside the SCL decoder becomes True) The example with real 5G data can be found here: https://github.com/catkira/py3gpp/blob/master/examples/test_py3gpp.ipynb

    I will squash all commits in this PR when its done. It solves this issue: https://github.com/NVlabs/sionna/issues/77

    Checklist

    [x] Detailed description [x] Added references to issues and discussions [ ] Added / modified documentation as needed [x] Added / modified unit tests as needed [ ] Passes all tests [x] Lint the code [ ] Performed a self review [ ] Ensure you Signed-off the commits. Required to accept contributions! [x] Co-authored with someone? Add Co-authored-by: user@domain and ensure they signed off their commits too.

    opened by catkira 1
  • support for dual polarization

    support for dual polarization

    Description

    Added:

    • dual polarization for the SSFM by the implementation of the corresponding Manakov equation.
    • dual polarization for the EDFA.
    • test cases for the latter two classes.

    Fixed:

    • noise bug as proposed by sebastian-xyz.
    • typos in documentation.

    Additional commits due to "sign"-requirement.

    Checklist

    [x] Detailed description [ ] Added references to issues and discussions [x] Added / modified documentation as needed [x] Added / modified unit tests as needed [x] Passes all tests [x] Lint the code [x] Performed a self review [x] Ensure you Signed-off the commits. Required to accept contributions! [x] Co-authored with someone? Add Co-authored-by: user@domain and ensure they signed off their commits too.

    opened by tuhlema 0
  • fix: calculation of step noise in SSFM

    fix: calculation of step noise in SSFM

    Description

    Fixes the calculation of the amplifier noise applied in each step of the SSFM if the Raman amplifier is used. The calculation for the noise power of the imaginary part was incorrect, since a division was used instead of a multiplication. To further simplify the code, the calculation of the noise power is only done once per step.

    Checklist

    • [x] Detailed description
    • [ ] Added references to issues and discussions
    • [x] Added / modified documentation as needed
    • [x] Added / modified unit tests as needed
    • [x] Passes all tests
    • [x] Lint the code
    • [x] Performed a self review
    • [x] Ensure you Signed-off the commits. Required to accept contributions!
    • [ ] Co-authored with someone? Add Co-authored-by: user@domain and ensure they signed off their commits too.
    opened by sebastian-xyz 0
  • fec: ldpc: _llr_max attribute overwritten in base LDPCBPDecoder class

    fec: ldpc: _llr_max attribute overwritten in base LDPCBPDecoder class

    Describe the bug _llr_max attribute is set in both LDPC5GDecoder and LDPCBPDecoder. Since the initialization of the latter is done after the setting in the child class, this might create some inconsistency.

    To Reproduce Static code analysis, so not required IMO.

    Expected behavior Set the value only in one place (e.g. in parent class and passing it as argument).

    Screenshots N/A

    System: N/A

    GPUs: N/A

    Additional context N/A

    opened by rediet-orange 1
Releases(v0.12.0)
  • v0.12.0(Dec 7, 2022)

    MIMO

    • Add MMSEPICDetector layer for MMSE-PIC detection, contribution from rwiesmayr
    • Add EPDetector layer for expectation propagation (EP) detection
    • Add KBestDetector for K-Best detection
    • Utility layer PAM2QAM now also supports soft information

    FEC

    • Add OSDDecoder layer for ordered statistics decoding (OSD)
    • Add submodule fec.linear for universal support of Linear Codes
    • Add support for max-log BCJR decoding to the convolutional and Turbo decoders
    • Align Turbo and convolutional encoders
    • Add support for code termination to convolutional codes
    • Add input LLR clipping to LDPC BP decoding

    OFDM

    • Add base class BaseChannelEstimator to ease the implementation of OFDM channel estimators
    • Add base class BaseChannelInterpolator to ease the implementation of OFDM channel interpolators
    • Add LMMSEInterpolator for LMMSE channel time and frequency interpolation and optional spatial smoothing
    • Add utility functions to compute time and frequency covariance matrices of TDL models
    • Add base class BaseEqualizer to ease implementation of OFDM MIMO equalizers
    • Add base classes BaseDetector and BaseDetectorWithPrior to ease the implementation of OFDM MIMO detectors without and with prior information
    • Add LinearDetector layer for LMMSE, MR, or ZF equalization followed by app or max-log demapping for OFDM MIMO detection
    • Add KBestDetector for K-Best-based OFDM MIMO detection
    • Add EPDetector for EP-based OFDM MIMO detection
    • Add MMSEPICDetector for MMSE-PIC-based OFDM MIMO detection
    • Add a setter to PilotPattern to support one-the-fly update of pilot symbols

    Channel

    • Add MIMO support to TDL channel models through the specification of arbitrary correlation matrices
    • Add support for TDL A30, B100, and C300 channel models
    • Fix base station orientation in gen_topology_* utilities

    Tutorials

    • Add a notebook showing how to use and compare some of the OFDM channel estimators and MIMO detectors available in Sionna

    MISC

    • Typos fix and new test cases
    • Drop support for TensorFlow 2.6
    Source code(tar.gz)
    Source code(zip)
  • v0.11.0(Sep 13, 2022)

    Features

    • Support for optical fiber simulations

      • Split step Fourier method (SSFM)
      • Erbium doped fiber amplifier
      • New tutorial notebook on optical fiber simulations
      • Refactorization of the channel documentation
    • BCJR decoder for convolutional codes

    • Support for Turbo codes

      • Turbo encoding layer
      • Turbo decoding layer
      • New interleaver layer supporting the LTE Turbo code interleaver patterns (cf. 36.212)
      • Utility functions for code generation and for puncturing
    • Improved scrambling layer

      • Support for custom scrambling sequences
      • Utility function to support scrambling sequences as defined in for 38.211
    • Adds LDPC rate-matching output interleaver to LDPC5GEncoder and LDPC5GDecoder

    • Utility function to generate random regular LDPC parity-check matrices

    • Zero-forcing (ZF) and matched filter (MF) MIMO equalizers

    • Tensor utility function for pseudo inverse computation

    • Several MIMO utility functions for channel whitening and complex-to-real valued representations

    • (OFDM) MIMO maximum likelihood detector with prior

    • Utility layer for computing logits on constellation points from LLRs

    • New tutorial on using the DeepMIMO dataset with Sionna

    • Restructured website

      • Made with Sionna section
      • Direct links to Github discussion/issues

    Breaking Changes

    • In LDPCBPDecoder and LDPC5GDecoder, keep_state has been replaced by stateful flag and the decoder now returns the states instead of keeping an internal reference
    • TDL and CDL power delay profiles are now normalized to have unit total power (related to issue #12).

    Fixes

    • (#38) Fixes issue with PanelArray()
    • (#43) Fixes issue with MLDetector
    • Adds support for TensorFlow 2.10
    • Bug fix in SymbolLogits2Moments
    • Bug fix in mapping module related to double precision
    • Adds missing reference of generate_dense_polar in sionna.fec.polar.__init__
    • Improves stability of graph mode in Polar SCL decoding
    • Issue of LDPC decoding when graph is not pruned
    • Fixes missing attribute in Linear Encoder
    • Improved selection of polynomials for convolutional codes
    • Removes deprecated items in pylintrc due to updated version of Lynter
    • Typos in the documentation
    • Corrects the LoS path power calculation oft the 3GPP 38.901 channel models
    • Fixes a bug in the effective noise variance computation of the lmmse_equalizer
    Source code(tar.gz)
    Source code(zip)
  • v0.10.0(Jun 29, 2022)

    New features

    • Universal FEC encoder for binary linear codes
    • Utility functions for FEC to
      • Convert parity-check matrix to generator matrix
      • Make generator matrix systematic
      • Generate dense Polar parity-check and generator matrices
      • Verify that generator and parity check matrix are orthogonal in GF(2)
    • Linear interpolator for OFDM channel estimation (with optional time-averaging)
    • MIMO maximum likelihood detector that computes either LLRs on bits or logits on constellation points
    • SymbolSource layer for sampling arbitrary constellations
    • PAMSource layer for sampling PAM constellations
    • The SymbolSource, PAMSource, QAMSource, and Mapper optionally return the indices of the constellation points and/or the bit labels
    • Utility layer to compute logits on constellation points to LLRs on bits (with optional priors)
    • Utility layer to compute the mean and variance of a constellation given logits on the points
    • Addition of integration tests

    Fixes

    • (#25) XLA compatibility with TF2.9 for the BP decoder
    • (#29) SNR property in PlotBER
    • Adds support for TF2.9
    • Minor bug fixes
    • Typos in the documentation
    Source code(tar.gz)
    Source code(zip)
  • v0.9.2(Jun 24, 2022)

    Fixes

    • Drop support for TensorFlow 2.5 as it no longer receives updates
    • Update minimum TensorFlow version requirements to address recent CVEs
    Source code(tar.gz)
    Source code(zip)
  • v0.9.1(May 31, 2022)

    Fixes

    • Solves deprecated warning in utils.metrics (#14)
    • Issue related to explicit interleaver seed in graph mode
    • Issues related to RessourceGridDemapper (#19)
    • Output shape of signal.utils.convolution()
    • Corrects year of Gallager quote in channel coding example notebook
    • Corrects Eb/No rate calculation in channel coding example notebook
    • Typos in documentation
    • Solves issue related to PanelArray.show() (#23)
    • Optimization of signal.utils.convolution() for complex-valued inputs
    Source code(tar.gz)
    Source code(zip)
  • v0.9.0(Apr 29, 2022)

    Features

    New Signal Module

    • Layers for up-/downsampling
    • Layers for  (trainable) filters (e.g., pulse shaping)
    • Layers for  (trainable) windowing functions
    • Utility functions for convolution, (I)FFT, PSD, and ACLR calculation
    • New example notebook on pulse-shaping

    Fixes

    • OFDMModulator issue
    • Removes several warnings during unittests
    Source code(tar.gz)
    Source code(zip)
  • v0.8.1(Apr 8, 2022)

    Fixes

    • OFDMDemodulator() issue for a cyclic_prefix equal to zero (closes github #6)
    • Fixes issue with Jupyter notebook requesting a token
    • Improve installation on macOS (closes github #2)
    • Other small bug fixes and enhancements
    Source code(tar.gz)
    Source code(zip)
  • v0.8.0(Mar 21, 2022)

    Features

    Forward error correction (FEC)

    • 5G LDPC codes including rate matching
    • 5G Polar codes including rate matching
    • Cyclic redundancy check (CRC)
    • Reed-Muller & Convolutional codes
    • Interleaving & Scrambling
    • Belief propagation (BP) decoder and variants
    • SC, SCL, and SCL-CRC Polar decoders
    • Viterbi decoder
    • Demapper with prior
    • EXIT chart simulations
    • Import of partity-check matrices in alist format

    Channel models

    • Additive white Gaussian noise (AWGN) channel
    • Flat-fading channel models with antenna correlation
    • 3GPP 38.901 TDL, CDL, UMa, UMi, RMa models
    • Import of channel impulse response from datasets
    • Channel output computed in time or frequency domain

    MIMO processing

    • Multiuser & multicell MIMO support
    • 3GPP 38.901 & custom antenna arrays/patterns
    • Zero forcing (ZF) precoding
    • Minimum mean squared error (MMSE) equalization

    Orthogonal frequency-division multiplexing (OFDM)

    • OFDM modulation & demodulation
    • Cyclic prefix insertion & removal
    • Flexible 5G slot-like frame structure
    • Arbitrary pilot patterns
    • LS channel estimation & Nearest neighbor interpolation
    Source code(tar.gz)
    Source code(zip)
Owner
NVIDIA Research Projects
NVIDIA Research Projects
NExT-QA: Next Phase of Question-Answering to Explaining Temporal Actions (CVPR2021)

NExT-QA We reproduce some SOTA VideoQA methods to provide benchmark results for our NExT-QA dataset accepted to CVPR2021 (with 1 'Strong Accept' and 2

Junbin Xiao 50 Nov 24, 2022
PaddleRobotics is an open-source algorithm library for robots based on Paddle, including open-source parts such as human-robot interaction, complex motion control, environment perception, SLAM positioning, and navigation.

简体中文 | English PaddleRobotics paddleRobotics是基于paddle的机器人开源算法库集,包括人机交互、复杂运动控制、环境感知、slam定位导航等开源算法部分。 人机交互 主动多模交互技术TFVT-HRI 主动多模交互技术是通过视觉、语音、触摸传感器等输入机器人

null 185 Dec 26, 2022
Detectron2 is FAIR's next-generation platform for object detection and segmentation.

Detectron2 is Facebook AI Research's next generation software system that implements state-of-the-art object detection algorithms. It is a ground-up r

Facebook Research 23.3k Jan 8, 2023
OpenMMLab's Next Generation Video Understanding Toolbox and Benchmark

Introduction English | 简体中文 MMAction2 is an open-source toolbox for video understanding based on PyTorch. It is a part of the OpenMMLab project. The m

OpenMMLab 2.7k Jan 7, 2023
Code for the paper "Next Generation Reservoir Computing"

Next Generation Reservoir Computing This is the code for the results and figures in our paper "Next Generation Reservoir Computing". They are written

OSU QuantInfo Lab 105 Dec 20, 2022
A Next Generation ConvNet by FaceBookResearch Implementation in PyTorch(Original) and TensorFlow.

ConvNeXt A Next Generation ConvNet by FaceBookResearch Implementation in PyTorch(Original) and TensorFlow. A FacebookResearch Implementation on A Conv

Raghvender 2 Feb 14, 2022
GT4SD, an open-source library to accelerate hypothesis generation in the scientific discovery process.

The GT4SD (Generative Toolkit for Scientific Discovery) is an open-source platform to accelerate hypothesis generation in the scientific discovery process. It provides a library for making state-of-the-art generative AI models easier to use.

Generative Toolkit 4 Scientific Discovery 142 Dec 24, 2022
Multiple paper open-source codes of the Microsoft Research Asia DKI group

?? Paper Code Collection (MSRA DKI Group) This repo hosts multiple open-source codes of the Microsoft Research Asia DKI Group. You could find the corr

Microsoft 249 Jan 8, 2023
Open source simulator for autonomous vehicles built on Unreal Engine / Unity, from Microsoft AI & Research

Welcome to AirSim AirSim is a simulator for drones, cars and more, built on Unreal Engine (we now also have an experimental Unity release). It is open

Microsoft 13.8k Jan 5, 2023
FAIR's research platform for object detection research, implementing popular algorithms like Mask R-CNN and RetinaNet.

Detectron is deprecated. Please see detectron2, a ground-up rewrite of Detectron in PyTorch. Detectron Detectron is Facebook AI Research's software sy

Facebook Research 25.5k Jan 7, 2023
A modular framework for vision & language multimodal research from Facebook AI Research (FAIR)

MMF is a modular framework for vision and language multimodal research from Facebook AI Research. MMF contains reference implementations of state-of-t

Facebook Research 5.1k Jan 4, 2023
Physics-Aware Training (PAT) is a method to train real physical systems with backpropagation.

Physics-Aware Training (PAT) is a method to train real physical systems with backpropagation. It was introduced in Wright, Logan G. & Onodera, Tatsuhiro et al. (2021)1 to train Physical Neural Networks (PNNs) - neural networks whose building blocks are physical systems.

McMahon Lab 230 Jan 5, 2023
Official Pytorch implementation of ICLR 2018 paper Deep Learning for Physical Processes: Integrating Prior Scientific Knowledge.

Deep Learning for Physical Processes: Integrating Prior Scientific Knowledge: Official Pytorch implementation of ICLR 2018 paper Deep Learning for Phy

emmanuel 47 Nov 6, 2022
Phy-Q: A Benchmark for Physical Reasoning

Phy-Q: A Benchmark for Physical Reasoning Cheng Xue*, Vimukthini Pinto*, Chathura Gamage* Ekaterina Nikonova, Peng Zhang, Jochen Renz School of Comput

null 29 Dec 19, 2022
Code repo for "RBSRICNN: Raw Burst Super-Resolution through Iterative Convolutional Neural Network" (Machine Learning and the Physical Sciences workshop in NeurIPS 2021).

RBSRICNN: Raw Burst Super-Resolution through Iterative Convolutional Neural Network An official PyTorch implementation of the RBSRICNN network as desc

Rao Muhammad Umer 6 Nov 14, 2022
FCA: Learning a 3D Full-coverage Vehicle Camouflage for Multi-view Physical Adversarial Attack

FCA: Learning a 3D Full-coverage Vehicle Camouflage for Multi-view Physical Adversarial Attack Case study of the FCA. The code can be find in FCA. Cas

IDRL 21 Dec 15, 2022
Source code for the GPT-2 story generation models in the EMNLP 2020 paper "STORIUM: A Dataset and Evaluation Platform for Human-in-the-Loop Story Generation"

Storium GPT-2 Models This is the official repository for the GPT-2 models described in the EMNLP 2020 paper [STORIUM: A Dataset and Evaluation Platfor

Nader Akoury 27 Dec 20, 2022
OpenGAN: Open-Set Recognition via Open Data Generation

OpenGAN: Open-Set Recognition via Open Data Generation ICCV 2021 (oral) Real-world machine learning systems need to analyze novel testing data that di

Shu Kong 90 Jan 6, 2023
Reference implementation of code generation projects from Facebook AI Research. General toolkit to apply machine learning to code, from dataset creation to model training and evaluation. Comes with pretrained models.

This repository is a toolkit to do machine learning for programming languages. It implements tokenization, dataset preprocessing, model training and m

Facebook Research 408 Jan 1, 2023