|
2887 | 2887 | "name": "stderr", |
2888 | 2888 | "output_type": "stream", |
2889 | 2889 | "text": [ |
2890 | | - "Operator `Kernel` ran in 0.68 s\n" |
| 2890 | + "Operator `Kernel` ran in 0.74 s\n" |
2891 | 2891 | ] |
2892 | | - }, |
2893 | | - { |
2894 | | - "data": { |
2895 | | - "text/plain": [ |
2896 | | - "PerformanceSummary([(PerfKey(name='section0', rank=None),\n", |
2897 | | - " PerfEntry(time=0.198681000000007, gflopss=0.0, gpointss=0.0, oi=0.0, ops=0, itershapes=[])),\n", |
2898 | | - " (PerfKey(name='section1', rank=None),\n", |
2899 | | - " PerfEntry(time=0.19470700000000477, gflopss=0.0, gpointss=0.0, oi=0.0, ops=0, itershapes=[])),\n", |
2900 | | - " (PerfKey(name='section2', rank=None),\n", |
2901 | | - " PerfEntry(time=0.14005600000000007, gflopss=0.0, gpointss=0.0, oi=0.0, ops=0, itershapes=[])),\n", |
2902 | | - " (PerfKey(name='section3', rank=None),\n", |
2903 | | - " PerfEntry(time=0.1434430000000003, gflopss=0.0, gpointss=0.0, oi=0.0, ops=0, itershapes=[]))])" |
2904 | | - ] |
2905 | | - }, |
2906 | | - "execution_count": 45, |
2907 | | - "metadata": {}, |
2908 | | - "output_type": "execute_result" |
2909 | 2892 | } |
2910 | 2893 | ], |
2911 | 2894 | "source": [ |
2912 | 2895 | "#NBVAL_IGNORE_OUTPUT\n", |
2913 | | - "op1 = Operator([eq_v,\n", |
| 2896 | + "from devito import switchconfig\n", |
| 2897 | + "\n", |
| 2898 | + "# Note: switchconfig(safe_math=True) is only required here to get consistent norms for testing purposes\n", |
| 2899 | + "# This is not required more widely and can be omitted in practical applications\n", |
| 2900 | + "with switchconfig(safe_math=True):\n", |
| 2901 | + " op1 = Operator([eq_v,\n", |
2914 | 2902 | " eq_p, eq_t,\n", |
2915 | 2903 | " eq_p_tr, eq_txx_tr, eq_tyy_tr]\n", |
2916 | 2904 | " + src_term + rec_term)\n", |
2917 | | - "op1(dt=dt)" |
| 2905 | + " op1(dt=dt)" |
2918 | 2906 | ] |
2919 | 2907 | }, |
2920 | 2908 | { |
|
3020 | 3008 | } |
3021 | 3009 | ], |
3022 | 3010 | "metadata": { |
| 3011 | + "kernelspec": { |
| 3012 | + "display_name": "Python 3 (ipykernel)", |
| 3013 | + "language": "python", |
| 3014 | + "name": "python3" |
| 3015 | + }, |
3023 | 3016 | "language_info": { |
3024 | | - "name": "python" |
| 3017 | + "codemirror_mode": { |
| 3018 | + "name": "ipython", |
| 3019 | + "version": 3 |
| 3020 | + }, |
| 3021 | + "file_extension": ".py", |
| 3022 | + "mimetype": "text/x-python", |
| 3023 | + "name": "python", |
| 3024 | + "nbconvert_exporter": "python", |
| 3025 | + "pygments_lexer": "ipython3", |
| 3026 | + "version": "3.11.5" |
3025 | 3027 | } |
3026 | 3028 | }, |
3027 | 3029 | "nbformat": 4, |
|
0 commit comments