Giter Club home page Giter Club logo

cds's Introduction

Co-domain Symmetry for Complex-Valued Deep Learning [CVPR 2022]

Official code implementation for CDS.

Requires Pytorch 1.9.0 and CUDA 11.0

Instructions:

To train the CDS-E model on various encodings of CIFAR10/100/SVHN datasets, please run

bash scripts/rgb_e.sh

To train the CDS-I model on various encodings of CIFAR10/100/SVHN datasets, please run

bash scripts/rgb_i.sh

To train the CDS-MSTAR model on MSTAR dataset, please run

bash scripts/mstar.sh

To train the CDS-Large model, please run

python train_big.py

CDS-Large pre-trained model weights

Please cite our work as:

@InProceedings{Singhal_2022_CVPR,
    author    = {Singhal, Utkarsh and Xing, Yifei and Yu, Stella X.},
    title     = {Co-Domain Symmetry for Complex-Valued Deep Learning},
    booktitle = {Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR)},
    month     = {June},
    year      = {2022},
    pages     = {681-690}
}

cds's People

Contributors

sutkarsh avatar

Stargazers

Girish Chandar G avatar Ke Wang avatar wootommy avatar  avatar

Watchers

James Cloos avatar  avatar

Forkers

neuralnut

cds's Issues

Colon separating config files.

The argument parser uses a colon to separate multiple config files. This can cause issues on Windows machines because of the colon present in fully resolved paths. For example, C:\path\to\config.yml will throw an error in the function parse_config() in config.py. The error is thrown because the loop on lines 52-55,

        for subpath in path.split(':'):
            with open(subpath) as fid:
                conf_add = yaml.load(fid, Loader=yaml.FullLoader)

will attempt to open a file named "C".

I played around with a solution that would allow the colon separator to be kept while supporting Windows paths and came up with this:

    # Open colon separated paths but watch out for Windows absolute paths like "C:\path\to\file.yml".
    path_iter = iter(path.split(':'))
    for subpath in path_iter:
        try:  # to open this subpath as is
            with open(subpath) as fid:
                conf_add = yaml.load(fid, Loader=yaml.FullLoader)
        except FileNotFoundError:  # Maybe this is a Windows machine with an absolute path?
            try:  # to get what may be the other part of the Windows fully defined path
                next_subpath = next(path_iter)
            except StopIteration:  # There isn't another part, this was an actual FileNotFound error.
                raise FileNotFoundError(f"No such file or directory: '{subpath}'")
            try:  # to open subpath and next_subpath combined as an absolute Windows path
                with open(subpath + ':' + next_subpath) as fid:
                    conf_add = yaml.load(fid, Loader=yaml.FullLoader)
            except (OSError, FileNotFoundError):  # This was an actual FileNotFound error.
                raise FileNotFoundError(f"No such files or directories: '{subpath}', '{subpath}:{next_subpath}'")

MSTAR Data

Hi, thanks a lot for sharing the code.
I am going to run your model on MSTAR but there is no such directory: /utkarsh/data/MSTAR/ as mentioned in code.
Thanks.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.