Skip to content

Set path for DMRG disk feature #975

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 11, 2022
Merged

Set path for DMRG disk feature #975

merged 1 commit into from
Sep 11, 2022

Conversation

emstoudenmire
Copy link
Collaborator

Description

Based on this forum question, allow users to set a custom path for write-to-disk mode of DMRG.

How Has This Been Tested?

Tested by modifying one of the example codes and verifying correct behavior, though didn't write a unit test for it.

Checklist:

  • My code follows the style guidelines of this project. Please run using JuliaFormatter; format(".") in the base directory of the repository (~/.julia/dev/ITensors) to format your code according to our style guidelines.
  • I have performed a self-review of my own code.
  • I have commented my code, particularly in hard-to-understand areas.
  • I have added tests that verify the behavior of the changes I made.
  • I have made corresponding changes to the documentation.
  • My changes generate no new warnings.
  • Any dependent changes have been merged and published in downstream modules.

@github-actions
Copy link
Contributor

Benchmark result

Judge result

Benchmark Report for /home/runner/work/ITensors.jl/ITensors.jl

Job Properties

  • Time of benchmarks:
    • Target: 10 Sep 2022 - 20:59
    • Baseline: 10 Sep 2022 - 21:13
  • Package commits:
    • Target: c52a39
    • Baseline: c381aa
  • Julia commits:
    • Target: afb6c6
    • Baseline: afb6c6
  • Julia command flags:
    • Target: None
    • Baseline: None
  • Environment variables:
    • Target: None
    • Baseline: None

Results

A ratio greater than 1.0 denotes a possible regression (marked with ❌), while a ratio less
than 1.0 denotes a possible improvement (marked with ✅). Only significant results - results
that indicate possible regressions or improvements - are shown below (thus, an empty table means that all
benchmark results remained invariant between builds).

ID time ratio memory ratio
["contract", "heff_2site"] 0.92 (5%) ✅ 1.00 (1%)
["contract", "matmul_20"] 0.94 (5%) ✅ 1.00 (1%)
["contract", "matmul_inplace_80"] 0.93 (5%) ✅ 1.00 (1%)
["getsetindex", "setindex! end"] 1.05 (5%) ❌ 1.00 (1%)
["getsetindex", "setindex!"] 1.06 (5%) ❌ 1.00 (1%)
["indexset", "constructor", "function"] 0.94 (5%) ✅ 1.00 (1%)
["indexset", "filter", "function"] 0.95 (5%) ✅ 1.00 (1%)
["indexset", "set_functions", "commoninds, ITensor"] 1.09 (5%) ❌ 1.00 (1%)
["inplace", "axpy!"] 0.93 (5%) ✅ 1.00 (1%)
["op", "op QN"] 1.12 (5%) ❌ 1.00 (1%)
["op", "op"] 0.91 (5%) ✅ 1.00 (1%)
["tagset", "tagset_unicode"] 1.05 (5%) ❌ 1.00 (1%)

Benchmark Group List

Here's a list of all the benchmark groups executed by this job:

  • ["autompo"]
  • ["contract"]
  • ["dmrg"]
  • ["getsetindex"]
  • ["indexset", "constructor"]
  • ["indexset", "filter"]
  • ["indexset", "set_functions"]
  • ["indexset", "set_functions", "uniqueinds"]
  • ["inplace"]
  • ["op"]
  • ["tagset"]

Julia versioninfo

Target

Julia Version 1.8.1
Commit afb6c60d69a (2022-09-06 15:09 UTC)
Platform Info:
  OS: Linux (x86_64-linux-gnu)
      Ubuntu 20.04.5 LTS
  uname: Linux 5.15.0-1019-azure #24~20.04.1-Ubuntu SMP Tue Aug 23 15:52:52 UTC 2022 x86_64 x86_64
  CPU: Intel(R) Xeon(R) Platinum 8171M CPU @ 2.60GHz: 
              speed         user         nice          sys         idle          irq
       #1  2095 MHz       3953 s          2 s        395 s      11342 s          0 s
       #2  2095 MHz      10057 s          1 s       1345 s       4358 s          0 s
  Memory: 6.781253814697266 GB (1478.4296875 MB free)
  Uptime: 1580.57 sec
  Load Avg:  1.0  1.01  0.88
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-13.0.1 (ORCJIT, skylake-avx512)
  Threads: 1 on 2 virtual cores

Baseline

Julia Version 1.8.1
Commit afb6c60d69a (2022-09-06 15:09 UTC)
Platform Info:
  OS: Linux (x86_64-linux-gnu)
      Ubuntu 20.04.5 LTS
  uname: Linux 5.15.0-1019-azure #24~20.04.1-Ubuntu SMP Tue Aug 23 15:52:52 UTC 2022 x86_64 x86_64
  CPU: Intel(R) Xeon(R) Platinum 8171M CPU @ 2.60GHz: 
              speed         user         nice          sys         idle          irq
       #1  2095 MHz       8413 s          2 s        677 s      15122 s          0 s
       #2  2095 MHz      13232 s          1 s       2027 s       9028 s          0 s
  Memory: 6.781253814697266 GB (1063.69921875 MB free)
  Uptime: 2435.58 sec
  Load Avg:  1.19  1.07  1.01
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-13.0.1 (ORCJIT, skylake-avx512)
  Threads: 1 on 2 virtual cores

Target result

Benchmark Report for /home/runner/work/ITensors.jl/ITensors.jl

Job Properties

  • Time of benchmark: 10 Sep 2022 - 20:59
  • Package commit: c52a39
  • Julia commit: afb6c6
  • Julia command flags: None
  • Environment variables: None

Results

Below is a table of this job's results, obtained by running the benchmarks.
The values listed in the ID column have the structure [parent_group, child_group, ..., key], and can be used to
index into the BaseBenchmarks suite to retrieve the corresponding benchmarks.
The percentages accompanying time and memory values in the below table are noise tolerances. The "true"
time/memory value for a given benchmark is expected to fall within this percentage of the reported value.
An empty cell means that the value was zero.

ID time GC time memory allocations
["autompo", "Quartic Hamiltonian"] 62.094 s (5%) 7.636 s 12.49 GiB (1%) 171115648
["autompo", "Quartic QN Hamiltonian"] 85.447 s (5%) 11.277 s 21.63 GiB (1%) 227269147
["contract", "heff_2site"] 8.059 ms (5%) 19.41 MiB (1%) 196
["contract", "matmul_100"] 38.603 μs (5%) 80.47 KiB (1%) 15
["contract", "matmul_20"] 2.478 μs (5%) 5.55 KiB (1%) 14
["contract", "matmul_40"] 4.286 μs (5%) 14.92 KiB (1%) 14
["contract", "matmul_60"] 10.200 μs (5%) 30.47 KiB (1%) 15
["contract", "matmul_80"] 17.902 μs (5%) 52.34 KiB (1%) 15
["contract", "matmul_inplace_100"] 32.103 μs (5%) 1.25 KiB (1%) 10
["contract", "matmul_inplace_20"] 1.340 μs (5%) 1.25 KiB (1%) 10
["contract", "matmul_inplace_40"] 2.867 μs (5%) 1.25 KiB (1%) 10
["contract", "matmul_inplace_60"] 7.867 μs (5%) 1.25 KiB (1%) 10
["contract", "matmul_inplace_80"] 14.101 μs (5%) 1.25 KiB (1%) 10
["dmrg", "1d_S=1_heisenberg"] 26.698 s (5%) 1.084 s 38.86 GiB (1%) 1932455
["dmrg", "1d_S=1_heisenberg_qn"] 12.217 s (5%) 1.157 s 9.80 GiB (1%) 55580830
["getsetindex", "getindex end"] 268.816 ns (5%) 800 bytes (1%) 5
["getsetindex", "getindex indval end"] 87.921 ns (5%) 384 bytes (1%) 3
["getsetindex", "getindex indval"] 91.953 ns (5%) 400 bytes (1%) 3
["getsetindex", "getindex"] 26.709 ns (5%) 16 bytes (1%) 1
["getsetindex", "setindex! end"] 367.834 ns (5%) 1.14 KiB (1%) 6
["getsetindex", "setindex! indval end"] 138.568 ns (5%) 736 bytes (1%) 3
["getsetindex", "setindex! indval"] 146.374 ns (5%) 752 bytes (1%) 3
["getsetindex", "setindex!"] 97.260 ns (5%) 368 bytes (1%) 1
["indexset", "constructor", "function"] 768.703 ns (5%) 2.20 KiB (1%) 11
["indexset", "constructor", "function, tuple"] 518.895 ns (5%) 2.09 KiB (1%) 7
["indexset", "filter", "function"] 244.256 ns (5%) 1.77 KiB (1%) 1
["indexset", "filter", "function, tuple"] 86.427 ns (5%) 368 bytes (1%) 1
["indexset", "filter", "kwargs"] 219.773 ns (5%) 1.77 KiB (1%) 1
["indexset", "set_functions", "commoninds, ITensor"] 568.407 ns (5%) 2.84 KiB (1%) 5
["indexset", "set_functions", "noncommoninds, ITensor"] 674.327 ns (5%) 2.84 KiB (1%) 5
["indexset", "set_functions", "prime, ITensor"] 207.257 ns (5%) 1.08 KiB (1%) 3
["indexset", "set_functions", "unioninds, ITensor"] 884.337 ns (5%) 4.23 KiB (1%) 6
["indexset", "set_functions", "uniqueinds", "3_inputs"] 688.951 ns (5%) 3.48 KiB (1%) 9
["indexset", "set_functions", "uniqueinds", "filter_not_tags"] 405.507 ns (5%) 1.23 KiB (1%) 4
["indexset", "set_functions", "uniqueinds", "filter_tags"] 268.133 ns (5%) 976 bytes (1%) 2
["indexset", "set_functions", "uniqueinds", "nofilter0"] 170.818 ns (5%) 464 bytes (1%) 2
["indexset", "set_functions", "uniqueinds", "nofilter2"] 211.928 ns (5%) 976 bytes (1%) 2
["indexset", "set_functions", "uniqueinds, ITensor"] 756.966 ns (5%) 2.92 KiB (1%) 7
["inplace", "axpy!"] 20.002 μs (5%) 79.42 KiB (1%) 16
["op", "op QN"] 10.201 μs (5%) 12.05 KiB (1%) 107
["op", "op"] 5.050 μs (5%) 5.55 KiB (1%) 45
["tagset", "tagset"] 321.914 ns (5%) 144 bytes (1%) 1
["tagset", "tagset_long"] 417.212 ns (5%) 144 bytes (1%) 1
["tagset", "tagset_unicode"] 497.503 ns (5%) 144 bytes (1%) 1

Benchmark Group List

Here's a list of all the benchmark groups executed by this job:

  • ["autompo"]
  • ["contract"]
  • ["dmrg"]
  • ["getsetindex"]
  • ["indexset", "constructor"]
  • ["indexset", "filter"]
  • ["indexset", "set_functions"]
  • ["indexset", "set_functions", "uniqueinds"]
  • ["inplace"]
  • ["op"]
  • ["tagset"]

Julia versioninfo

Julia Version 1.8.1
Commit afb6c60d69a (2022-09-06 15:09 UTC)
Platform Info:
  OS: Linux (x86_64-linux-gnu)
      Ubuntu 20.04.5 LTS
  uname: Linux 5.15.0-1019-azure #24~20.04.1-Ubuntu SMP Tue Aug 23 15:52:52 UTC 2022 x86_64 x86_64
  CPU: Intel(R) Xeon(R) Platinum 8171M CPU @ 2.60GHz: 
              speed         user         nice          sys         idle          irq
       #1  2095 MHz       3953 s          2 s        395 s      11342 s          0 s
       #2  2095 MHz      10057 s          1 s       1345 s       4358 s          0 s
  Memory: 6.781253814697266 GB (1478.4296875 MB free)
  Uptime: 1580.57 sec
  Load Avg:  1.0  1.01  0.88
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-13.0.1 (ORCJIT, skylake-avx512)
  Threads: 1 on 2 virtual cores

Baseline result

Benchmark Report for /home/runner/work/ITensors.jl/ITensors.jl

Job Properties

  • Time of benchmark: 10 Sep 2022 - 21:13
  • Package commit: c381aa
  • Julia commit: afb6c6
  • Julia command flags: None
  • Environment variables: None

Results

Below is a table of this job's results, obtained by running the benchmarks.
The values listed in the ID column have the structure [parent_group, child_group, ..., key], and can be used to
index into the BaseBenchmarks suite to retrieve the corresponding benchmarks.
The percentages accompanying time and memory values in the below table are noise tolerances. The "true"
time/memory value for a given benchmark is expected to fall within this percentage of the reported value.
An empty cell means that the value was zero.

ID time GC time memory allocations
["autompo", "Quartic Hamiltonian"] 62.550 s (5%) 7.791 s 12.49 GiB (1%) 171115661
["autompo", "Quartic QN Hamiltonian"] 86.418 s (5%) 11.328 s 21.63 GiB (1%) 227269534
["contract", "heff_2site"] 8.759 ms (5%) 19.41 MiB (1%) 196
["contract", "matmul_100"] 38.303 μs (5%) 80.47 KiB (1%) 15
["contract", "matmul_20"] 2.622 μs (5%) 5.55 KiB (1%) 14
["contract", "matmul_40"] 4.286 μs (5%) 14.92 KiB (1%) 14
["contract", "matmul_60"] 10.701 μs (5%) 30.47 KiB (1%) 15
["contract", "matmul_80"] 18.101 μs (5%) 52.34 KiB (1%) 15
["contract", "matmul_inplace_100"] 32.103 μs (5%) 1.25 KiB (1%) 10
["contract", "matmul_inplace_20"] 1.390 μs (5%) 1.25 KiB (1%) 10
["contract", "matmul_inplace_40"] 2.911 μs (5%) 1.25 KiB (1%) 10
["contract", "matmul_inplace_60"] 7.834 μs (5%) 1.25 KiB (1%) 10
["contract", "matmul_inplace_80"] 15.201 μs (5%) 1.25 KiB (1%) 10
["dmrg", "1d_S=1_heisenberg"] 27.797 s (5%) 1.250 s 38.86 GiB (1%) 1932453
["dmrg", "1d_S=1_heisenberg_qn"] 11.898 s (5%) 1.091 s 9.80 GiB (1%) 55579828
["getsetindex", "getindex end"] 268.816 ns (5%) 800 bytes (1%) 5
["getsetindex", "getindex indval end"] 84.718 ns (5%) 384 bytes (1%) 3
["getsetindex", "getindex indval"] 90.490 ns (5%) 400 bytes (1%) 3
["getsetindex", "getindex"] 27.009 ns (5%) 16 bytes (1%) 1
["getsetindex", "setindex! end"] 349.298 ns (5%) 1.14 KiB (1%) 6
["getsetindex", "setindex! indval end"] 138.456 ns (5%) 736 bytes (1%) 3
["getsetindex", "setindex! indval"] 145.141 ns (5%) 752 bytes (1%) 3
["getsetindex", "setindex!"] 92.080 ns (5%) 368 bytes (1%) 1
["indexset", "constructor", "function"] 815.331 ns (5%) 2.20 KiB (1%) 11
["indexset", "constructor", "function, tuple"] 511.560 ns (5%) 2.09 KiB (1%) 7
["indexset", "filter", "function"] 257.198 ns (5%) 1.77 KiB (1%) 1
["indexset", "filter", "function, tuple"] 84.266 ns (5%) 368 bytes (1%) 1
["indexset", "filter", "kwargs"] 220.760 ns (5%) 1.77 KiB (1%) 1
["indexset", "set_functions", "commoninds, ITensor"] 521.514 ns (5%) 2.84 KiB (1%) 5
["indexset", "set_functions", "noncommoninds, ITensor"] 675.497 ns (5%) 2.84 KiB (1%) 5
["indexset", "set_functions", "prime, ITensor"] 203.236 ns (5%) 1.08 KiB (1%) 3
["indexset", "set_functions", "unioninds, ITensor"] 870.865 ns (5%) 4.23 KiB (1%) 6
["indexset", "set_functions", "uniqueinds", "3_inputs"] 702.139 ns (5%) 3.48 KiB (1%) 9
["indexset", "set_functions", "uniqueinds", "filter_not_tags"] 387.597 ns (5%) 1.23 KiB (1%) 4
["indexset", "set_functions", "uniqueinds", "filter_tags"] 268.136 ns (5%) 976 bytes (1%) 2
["indexset", "set_functions", "uniqueinds", "nofilter0"] 172.794 ns (5%) 464 bytes (1%) 2
["indexset", "set_functions", "uniqueinds", "nofilter2"] 206.589 ns (5%) 976 bytes (1%) 2
["indexset", "set_functions", "uniqueinds, ITensor"] 736.276 ns (5%) 2.92 KiB (1%) 7
["inplace", "axpy!"] 21.502 μs (5%) 79.42 KiB (1%) 16
["op", "op QN"] 9.100 μs (5%) 12.05 KiB (1%) 107
["op", "op"] 5.567 μs (5%) 5.55 KiB (1%) 45
["tagset", "tagset"] 314.189 ns (5%) 144 bytes (1%) 1
["tagset", "tagset_long"] 403.566 ns (5%) 144 bytes (1%) 1
["tagset", "tagset_unicode"] 472.122 ns (5%) 144 bytes (1%) 1

Benchmark Group List

Here's a list of all the benchmark groups executed by this job:

  • ["autompo"]
  • ["contract"]
  • ["dmrg"]
  • ["getsetindex"]
  • ["indexset", "constructor"]
  • ["indexset", "filter"]
  • ["indexset", "set_functions"]
  • ["indexset", "set_functions", "uniqueinds"]
  • ["inplace"]
  • ["op"]
  • ["tagset"]

Julia versioninfo

Julia Version 1.8.1
Commit afb6c60d69a (2022-09-06 15:09 UTC)
Platform Info:
  OS: Linux (x86_64-linux-gnu)
      Ubuntu 20.04.5 LTS
  uname: Linux 5.15.0-1019-azure #24~20.04.1-Ubuntu SMP Tue Aug 23 15:52:52 UTC 2022 x86_64 x86_64
  CPU: Intel(R) Xeon(R) Platinum 8171M CPU @ 2.60GHz: 
              speed         user         nice          sys         idle          irq
       #1  2095 MHz       8413 s          2 s        677 s      15122 s          0 s
       #2  2095 MHz      13232 s          1 s       2027 s       9028 s          0 s
  Memory: 6.781253814697266 GB (1063.69921875 MB free)
  Uptime: 2435.58 sec
  Load Avg:  1.19  1.07  1.01
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-13.0.1 (ORCJIT, skylake-avx512)
  Threads: 1 on 2 virtual cores

Runtime information

Runtime Info
BLAS #threads 1
BLAS.vendor() openblas64
Sys.CPU_THREADS 2

lscpu output:

Architecture:                    x86_64
CPU op-mode(s):                  32-bit, 64-bit
Byte Order:                      Little Endian
Address sizes:                   46 bits physical, 48 bits virtual
CPU(s):                          2
On-line CPU(s) list:             0,1
Thread(s) per core:              1
Core(s) per socket:              2
Socket(s):                       1
NUMA node(s):                    1
Vendor ID:                       GenuineIntel
CPU family:                      6
Model:                           85
Model name:                      Intel(R) Xeon(R) Platinum 8171M CPU @ 2.60GHz
Stepping:                        4
CPU MHz:                         2095.221
BogoMIPS:                        4190.44
Hypervisor vendor:               Microsoft
Virtualization type:             full
L1d cache:                       64 KiB
L1i cache:                       64 KiB
L2 cache:                        2 MiB
L3 cache:                        35.8 MiB
NUMA node0 CPU(s):               0,1
Vulnerability Itlb multihit:     KVM: Mitigation: VMX unsupported
Vulnerability L1tf:              Mitigation; PTE Inversion
Vulnerability Mds:               Mitigation; Clear CPU buffers; SMT Host state unknown
Vulnerability Meltdown:          Mitigation; PTI
Vulnerability Mmio stale data:   Vulnerable: Clear CPU buffers attempted, no microcode; SMT Host state unknown
Vulnerability Retbleed:          Vulnerable
Vulnerability Spec store bypass: Vulnerable
Vulnerability Spectre v1:        Mitigation; usercopy/swapgs barriers and __user pointer sanitization
Vulnerability Spectre v2:        Mitigation; Retpolines, STIBP disabled, RSB filling
Vulnerability Srbds:             Not affected
Vulnerability Tsx async abort:   Mitigation; Clear CPU buffers; SMT Host state unknown
Flags:                           fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ss ht syscall nx pdpe1gb rdtscp lm constant_tsc rep_good nopl xtopology cpuid pni pclmulqdq ssse3 fma cx16 pcid sse4_1 sse4_2 movbe popcnt aes xsave avx f16c rdrand hypervisor lahf_lm abm 3dnowprefetch invpcid_single pti fsgsbase bmi1 hle avx2 smep bmi2 erms invpcid rtm avx512f avx512dq rdseed adx smap clflushopt avx512cd avx512bw avx512vl xsaveopt xsavec xsaves md_clear
Cpu Property Value
Brand Intel(R) Xeon(R) Platinum 8171M CPU @ 2.60GHz
Vendor :Intel
Architecture :Skylake
Model Family: 0x06, Model: 0x55, Stepping: 0x04, Type: 0x00
Cores 2 physical cores, 2 logical cores (on executing CPU)
No Hyperthreading hardware capability detected
Clock Frequencies Not supported by CPU
Data Cache Level 1:3 : (32, 1024, 36608) kbytes
64 byte cache line size
Address Size 48 bits virtual, 46 bits physical
SIMD 512 bit = 64 byte max. SIMD vector size
Time Stamp Counter TSC is accessible via rdtsc
TSC increased at every clock cycle (non-invariant TSC)
Perf. Monitoring Performance Monitoring Counters (PMC) are not supported
Hypervisor Yes, Microsoft

@codecov-commenter
Copy link

codecov-commenter commented Sep 10, 2022

Codecov Report

Merging #975 (68d55c8) into main (d36f198) will increase coverage by 0.01%.
The diff coverage is 83.33%.

@@            Coverage Diff             @@
##             main     #975      +/-   ##
==========================================
+ Coverage   66.53%   66.54%   +0.01%     
==========================================
  Files          91       91              
  Lines        9918     9921       +3     
==========================================
+ Hits         6599     6602       +3     
  Misses       3319     3319              
Impacted Files Coverage Δ
src/mps/abstractmps.jl 85.24% <75.00%> (+0.03%) ⬆️
src/mps/diskprojmpo.jl 80.00% <100.00%> (ø)
src/mps/dmrg.jl 84.49% <100.00%> (+0.12%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@emstoudenmire emstoudenmire merged commit 29d9e0a into main Sep 11, 2022
@emstoudenmire emstoudenmire deleted the write_path branch September 11, 2022 02:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants