FLImaging 7.8.25.3
ComputationalGraphAugmentationForInstanceSegmentation.h
1#pragma once
2
3#if _MSC_VER >= 1900 && defined(_M_X64)
4
5#include "Tensor.h"
6#include "BackendLabel.h"
7#include "ComputationalGraphAugmentationBase.h"
8
9namespace FLImaging
10{
11 namespace AI
12 {
13
15 template<typename T>
16 class CInternalAugmentationForInstanceSegmentation;
17
18 template <typename T>
19 class FL_EXPORT CComputationalGraphAugmentationForInstanceSegmentation : public CComputationalGraphAugmentationBase<T>
20 {
21 private:
22 CComputationalGraphAugmentationForInstanceSegmentation();
23
24 protected:
25 CComputationalGraphAugmentationForInstanceSegmentation(const CComputationalGraphAugmentationForInstanceSegmentation<T>& cg);
26
27 public:
28 CComputationalGraphAugmentationForInstanceSegmentation(const CComputationalBase<T>& cbOperand, const CAugmentationParameters& apParams);
29 CComputationalGraphAugmentationForInstanceSegmentation(const CComputationalBase<T>& cbOperand, const CAugmentationParameters* pApParams);
30 virtual ~CComputationalGraphAugmentationForInstanceSegmentation();
31
32 virtual CComputationalBase<T>* Clone() const override;
33 virtual CTensor<T>& Forward() override;
34
35 virtual const CResult GetBinaryData(Base::CFLData& fldBinary, bool bSuperClass = false, int32_t i32Version = -1, bool bDumpMode = false) const override;
36 virtual const CResult GetBinaryData(Base::CFLData* pFldBinary, bool bSuperClass = false, int32_t i32Version = -1, bool bDumpMode = false) const override;
37
38 virtual const CResult SetBinaryData(const Base::CFLData& fldBinary, int64_t* pI64Offset = nullptr) override;
39 virtual const CResult SetBinaryData(const Base::CFLData* pFldBinary, int64_t* pI64Offset = nullptr) override;
40
41 DeclareGetClassType();
42 SupportToDuplicateObjectWithoutCreateNewObject(CComputationalGraphAugmentationForInstanceSegmentation, *this);
43
44 protected:
45 public:
46 DeclareGetSignletonObject(CComputationalGraphAugmentationForInstanceSegmentation);
47 private:
48 template <typename T> friend class CInternalAugmentationForInstanceSegmentation;
49 };
50
51 #define CCGFAugmentationIS(...) (*(new CComputationalGraphAugmentationForInstanceSegmentation<float>(__VA_ARGS__)))
52 #define CCGDAugmentationIS(...) (*(new CComputationalGraphAugmentationForInstanceSegmentation<double>(__VA_ARGS__)))
53
54 #define CCGTAugmentationIS(T, ...) (*(new CComputationalGraphAugmentationForInstanceSegmentation<T>(__VA_ARGS__)))
55 }
56}
57
58#endif
Augmentation Parameter Class By transforming the images, it increases the diversity of training image...
Definition AugmentationParameters.h:69
Definition AlgorithmAIBase.h:18