mindflow.geometry.TimeDomain
- class mindflow.geometry.TimeDomain(name, start=0.0, end=1.0, dtype=np.float32, sampling_config=None)[source]
Definition of Time Domain.
- Parameters
name (str) – name of the time domain.
start (Union[int, float]) – start of the time domain. Default:
0.0
.end (Union[int, float]) – end of the time domain. Default:
1.0
.dtype (numpy.dtype) – Data type of sampled point data type. Default:
numpy.float32
.sampling_config (SamplingConfig) – sampling configuration. Default:
None
.
- Supported Platforms:
Ascend
GPU
Examples
>>> from mindflow.geometry import generate_sampling_config, TimeDomain >>> time_config = dict({ ... 'domain': dict({ ... 'random_sampling': True, ... 'size': 100, ... 'sampler': 'lhs' ... }) ... }) >>> time_domain = TimeDomain("time", 0.0, 1.0, sampling_config=generate_sampling_config(time_config)) >>> domain = time_domain.sampling(geom_type="domain") >>> print(domain.shape) (100, 1)