* Add save_best option in eval_hook.
* Update meta to fix best model can not test bug
* refactor with _do_evaluate
* remove redundent
* add meta
Co-authored-by: Jiarui XU <xvjiarui0826@gmail.com>
* Add arg: final_reshape to control if converting output feature information from NLC to NCHW;
* Fix the default value of final_reshape;
* Modify arg: final_reshape to arg: out_shape;
* Fix some unit test bug;
* Adjust vision transformer backbone architectures;
* Add DropPath, trunc_normal_ for VisionTransformer implementation;
* Add class token buring intermediate period and remove it during final period;
* Fix some parameters loss bug;
* * Store intermediate token features and impose no processes on them;
* Remove class token and reshape entire token feature from NLC to NCHW;
* Fix some doc error
* Add a arg for VisionTransformer backbone to control if input class token into transformer;
* Add stochastic depth decay rule for DropPath;
* * Fix output bug when input_cls_token=False;
* Add related unit test;
* * Add arg: out_indices to control model output;
* Add unit test for DropPath;
* Apply suggestions from code review
Co-authored-by: Jerry Jiarui XU <xvjiarui0826@gmail.com>
* support reading class_weight from file in loss function
* add unit test of loss with class_weight from file
* minor fix
* move get_class_weight to utils
* vit backbone
* fix lint
* add docstrings and fix pretrained pos_embed dim not match prob
* add unittest for vit
* fix lint
* add vit based fcn configs
* fix import error
* support multiple resolution input images
* upsample pos_embed at init_weights
* support resize pos_embed at evaluation
* fix training errors
* add more unitest code for vit backbone
* unitest for uncovered code
* add norm_eval unittest
* refactor _pos_embeding
* minor change
* change var name
* rafactor init_weight
* load weights after resize
* ignore 'module' in pretrain checkpoint
* add with_cp
* add with_cp
Co-authored-by: Jiarui XU <xvjiarui0826@gmail.com>
* Add support for Pascal Context 59 classes (#459)
* Create PascalContextDataset59 class in mmseg/datasets/pascal_context.py;
* Set reduce_zero_label=True for train_pipeline and PascalContextDataset59;
* Add some configs for Pascal-Context 59 classes training and testing;
* Try to solve the problem about "fence(IoU)=nan grass(IoU)=0";
* Continue(1): Try to solve the problem about "fence(IoU)=nan grass(IoU)=0";
* ignore files and folders named tempxxx;
* Continue(2): Try to solve the problem about "fence(IoU)=nan grass(IoU)=0";
* Modify the calculation of IoU;
* Modify the CLASSES order of PascalContextDataset;
* Add "fcn", "deeplabv3", "deeplabv3+", "pspnet" config file for model training based on PascalContextDataset59;
Add some ignore items in ".gitignore";
* fix the bug "test_cfg specified in both outer field and model field " of pspnet config file;
* * Clean unnecessary codes;
* Add weighs link, config link, log link and evaluation results about PascalContextDataset59 in README.md
* Add command line argument: "-p | --port", this arg can change the transmit port when you transmit data to distributed machine.
* * Remove rebundant config files;
* Remove "-p|--port" command argument;
Co-authored-by: Jiarui XU <xvjiarui0826@gmail.com>
* Fix fence(IoU) = 0 when training on PascalContextDataset59;
* Add a test case in test_metrics() of tests/test_metrics.py to test the bug caused by torch.histc;
* Update tests/test_metrics.py
Co-authored-by: Jerry Jiarui XU <xvjiarui0826@gmail.com>
Co-authored-by: Jerry Jiarui XU <xvjiarui0826@gmail.com>
* pytorch metrics impl and test
* support list[str] input, delete unused test code and delete numpy version
* modify input data type
* add docstring and unitest of filename inputs
* add indents in docstring and use tempfile lib to create dir
* using with statement
* Support fcn dilate 6
* Support dilate in FCNHead
* configs for cityscapse dataset
* add configs for pytorch pretrained model
* update README
* add fps test results
* add memory test results and links
* modify log names
* Update mmseg/models/decode_heads/fcn_head.py
Co-authored-by: Jerry Jiarui XU <xvjiarui0826@gmail.com>
* Support resize data augmentation according to original image size (img_scale=None and retio_range is tuple)
* fix docstring
* fix bug
* add unittest
* img_scale=None in TTA
* fix bug
* add unittest
* fix typos
* fix bug
* add inference test
* fix E501 line too long (81 > 79 characters
* fix wrong config path
* fix num of augmentations (2) != num of image meta (1)
* Update test_inference.py
Co-authored-by: Jerry Jiarui XU <xvjiarui0826@gmail.com>
* add dice evaluation metric
* add dice evaluation metric
* add dice evaluation metric
* support 2 metrics
* support 2 metrics
* support 2 metrics
* support 2 metrics
* fix docstring
* use np.round once for all
* Add Pascal Context to mmsegmentation
* Add benchmark result to Pascal Context
* fix mmcv version
* fix code syntax
* fix code syntax again
* Update mmseg/models/segmentors/encoder_decoder.py
update hint
Co-authored-by: Jerry Jiarui XU <xvjiarui0826@gmail.com>
* update comment
* fix pascal context model path
* fix model path mistake again
* fix model path mistake again
* fix model path mistakes again
Co-authored-by: Jerry Jiarui XU <xvjiarui0826@gmail.com>
* fix acc and iou compute nan problem
* fix acc and iou compute nan problem
* add nan_to_num args for mean_iou
* add nan_to_num args for mean_iou
* add nan_to_num args for mean_iou
* add nan_to_num args for mean_iou
* add nan_to_num args for mean_iou
* Update mmseg/core/evaluation/mean_iou.py
* Update mean_iou.py
* Update mean_iou.py
Co-authored-by: Jerry Jiarui XU <xvjiarui0826@gmail.com>
* Support for custom classes
* Fix test
* Fix pre-commit
* Add pipeline logic for custom classes
* Fix minor issues, fix test
* Fix issues from PR review
* Fix tests
* Remove palette as str
* Rename old_to_new_ids to label_map
* Test for load_anns
* Remove get_palette function
* fixed temp
* Add subset of palette, remove palette as arg
* minor update
Co-authored-by: Jiarui XU <xvjiarui0826@gmail.com>
* init commit: fast_scnn
* 247917iters
* 4x8_80k
* configs placed in configs_unify. 4x8_80k exp.running.
* mmseg/utils/collect_env.py modified to support Windows
* study on lr
* bug in configs_unify/***/cityscapes.py fixed.
* lr0.08_100k
* lr_power changed to 1.2
* log_config by_epoch set to False.
* lr1.2
* doc strings added
* add fast_scnn backbone test
* 80k 0.08,0.12
* add 450k
* fast_scnn test: fix BN bug.
* Add different config files into configs/
* .gitignore recovered.
* configs_unify del
* .gitignore recovered.
* delete sub-optimal config files of fast-scnn
* Code style improved.
* add docstrings to component modules of fast-scnn
* relevant files modified according to Jerry's instructions
* relevant files modified according to Jerry's instructions
* lint problems fixed.
* fast_scnn config extremely simplified.
* InvertedResidual
* fixed padding problems
* add unit test for inverted_residual
* add unit test for inverted_residual: debug 0
* add unit test for inverted_residual: debug 1
* add unit test for inverted_residual: debug 2
* add unit test for inverted_residual: debug 3
* add unit test for sep_fcn_head: debug 0
* add unit test for sep_fcn_head: debug 1
* add unit test for sep_fcn_head: debug 2
* add unit test for sep_fcn_head: debug 3
* add unit test for sep_fcn_head: debug 4
* add unit test for sep_fcn_head: debug 5
* FastSCNN type(dwchannels) changed to tuple.
* t changed to expand_ratio.
* Spaces fixed.
* Update mmseg/models/backbones/fast_scnn.py
Co-authored-by: Jerry Jiarui XU <xvjiarui0826@gmail.com>
* Update mmseg/models/decode_heads/sep_fcn_head.py
Co-authored-by: Jerry Jiarui XU <xvjiarui0826@gmail.com>
* Update mmseg/models/decode_heads/sep_fcn_head.py
Co-authored-by: Jerry Jiarui XU <xvjiarui0826@gmail.com>
* Docstrings fixed.
* Docstrings fixed.
* Inverted Residual kept coherent with mmcl.
* Inverted Residual kept coherent with mmcl. Debug 0
* _make_layer parameters renamed.
* final commit
* Arg scale_factor deleted.
* Expand_ratio docstrings updated.
* final commit
* Readme for Fast-SCNN added.
* model-zoo.md modified.
* fast_scnn README updated.
* Move InvertedResidual module into mmseg/utils.
* test_inverted_residual module corrected.
* test_inverted_residual.py moved.
* encoder_decoder modified to avoid bugs when running PSPNet.
getting_started.md bug fixed.
* Revert "encoder_decoder modified to avoid bugs when running PSPNet. "
This reverts commit dd0aadfb
Co-authored-by: Jerry Jiarui XU <xvjiarui0826@gmail.com>