Ben Chuanlong Du's Blog

It is never too late to learn.

Device Managment in PyTorch

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

  1. Modules can hold parameters of different types on different devices, so it's not always possible to unambiguously determine the device. The recommended workflow in PyTorch is to create the device object …

Time Series Analysis

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

In statistics, a unit root test tests whether a time series variable is non-stationary using an autoregressive model. A well-known test that is valid in large samples is the augmented Dickey …

Experiment Design

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

  1. Complete Randomized Design (CRD)

  2. Randomized Complete Block Design (CBD)

    • same RNE as CRD
  3. Latin Square Design (LSD)
    • same RNE as CRD
  4. Balanced Incomplete Block Design

    • all treatments cannot fit in any …

Sampling Methods

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

Probability Sampling

  • Random Sampling

  • Systematic Sampling

  • Stratified Sampling

Non-probability Sampling

  • Convenience Sampling

  • Judgement Sampling

  • Quota Sampling

  • Snowball Sampling

bias

Make Your Model Training Reproducible in PyTorch

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

The PyTorch doc Reproducibility has very detailed instructions on how to make your model training reproducible. Basically, you need the following code.

torch.manual_seed(args.seed)
np.random.seed(args.seed …