This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import importlib | |
import os | |
node_list = [ #Add list of .py files containing nodes here | |
"sampler_tonemap" | |
] | |
NODE_CLASS_MAPPINGS = {} | |
NODE_DISPLAY_NAME_MAPPINGS = {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Since we're using the nvidia/cuda base image, this requires nvidia-container-toolkit installed on the host system to pass through the drivers to the container. | |
# see: https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/latest/install-guide.html | |
# If you've just installed nvidia-container-toolkit, you may need to restart the docker daemon before it will detect the GPU | |
FROM nvidia/cuda:12.3.0-runtime-ubuntu22.04 AS final | |
WORKDIR /app | |
# Install Git and Git LFS | |
RUN apt-get update && apt-get install -y curl wget | |
RUN curl -s https://packagecloud.io/install/repositories/github/git-lfs/script.deb.sh | bash && apt-get install -y git-lfs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/bash | |
sudo apt-get install -y gnome-session-flashback | |
echo "you must restart - on login click the gear and choose gnome flashback (metacity)" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
viewedFiles.forEach(viewedFile => { | |
const currentFile = document.querySelectorAll(`div[data-path="${viewedFile.path}"]`)[0] || undefined; | |
if(currentFile) { | |
let currentDiffstat = currentFile.querySelectorAll("span.diffstat")[0].getAttribute('aria-label'); | |
let match = viewedFile.diffstats === currentDiffstat; | |
console.log(`match: ${match} - ${viewedFile.path} - viewedDiffstat: ${viewedFile.diffstats}, currentDiffstat: ${currentDiffstat}`); | |
if(match) { | |
let checkbox = currentFile.querySelectorAll('input[type="checkbox"]')[0]; | |
let viewed = checkbox.checked || false; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
select distinct(t.name), s.row_count from sys.tables t | |
join sys.dm_db_partition_stats s | |
on t.object_id = s.object_id | |
where t.is_ms_shipped = 0 | |
order by row_count desc; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT XEvent.query('(event/data/value/deadlock)[1]') AS DeadlockGraph | |
FROM ( | |
SELECT XEvent.query('.') AS XEvent | |
FROM ( | |
SELECT CAST(target_data AS XML) AS TargetData | |
FROM sys.dm_xe_session_targets st | |
INNER JOIN sys.dm_xe_sessions s ON s.address = st.event_session_address | |
WHERE s.NAME = 'system_health' | |
AND st.target_name = 'ring_buffer' | |
) AS Data |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT qs.last_logical_reads, st.text, qp.query_plan | |
FROM sys.dm_exec_query_stats qs | |
CROSS APPLY sys.dm_exec_sql_text(qs.sql_handle) st | |
CROSS APPLY sys.dm_exec_query_plan(qs.plan_handle) qp | |
WHERE st.text LIKE '%extent1%' -- Quick and dirty check for a LINQ query | |
AND qp.dbid = DB_ID('AdventureWorks2012_big') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
select | |
ps.object_id, | |
idx.name, | |
idx.type_desc, | |
ps.alloc_unit_type_desc, | |
ps.avg_fragmentation_in_percent, | |
ps.fragment_count, | |
ps.avg_fragment_size_in_pages, | |
ps.page_count | |
from |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function updateTimeLogged() { | |
var time = $("#log_hours").val() + "h " + $("#log_minutes").val() + "m"; | |
$('#log-work-time-logged').val(time); | |
} | |
$(document).on("change", "#log_hours", function(event) { | |
updateTimeLogged(); | |
}); | |
$(document).on("change", "#log_minutes", function(event) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$('.biz-listing-large').each(function(index, listItem) { | |
var shopName = $(listItem).find('.biz-name').text().trim(); | |
var address = $(listItem).find('address').text().trim().replace(/Auckland/g,", Auckland"); | |
console.log(shopName + "," + address); | |
}); |
NewerOlder